there already are languages for web programming like PHP and ASP? How is javascript different?
PHP and ASP both are used for web based programming, however they are server-side scripting languages. It means that to process those languages, a web server is required. The client request is sent to the web-server which processes the language commands and sends the required info or directions back to the user’s browser like Internet Explorer, Firefox etc.
Javascript on the other hand is a Client-side scripting language. Means that it is processed by the browser on the client’s(website visitor) computer and it doesn’t need a web server to work.
When you press a submit button on a PHP page, there is a few seconds wait before the required results appear and you can see the browser busy working sign (in Internet explorer, the rotating ‘e’). This is the time for sending request to the server and receiving data. On the other hand, try this javascript based calculator .CLICK HERE . the results are there the instant you click the submit button. Besides PHP and ASP are the choice when you need to add database functionality to your websites. Javascript cannot work with databases.
No comments:
Post a Comment
Thank you for your valuable comment