Article
Advanced Web Design: A Primer
Server-Side Scripting Languages
Server-side scripting languages, such as PHP, ASP, and PerlScript, are all intended to fulfill the same role as CGI (allowing the Web server to run a specialized program in response to a browser request) without the burden of launching an external program for every request.
By installing a plug-in, you can “teach” Web server software how to do things like run programs written in Perl or PHP (see below for descriptions of these) all by itself, instead of having to ask the operating system to run them as separate programs. When a Web page containing one of these languages is requested, the Web server uses its internal plug-in to run the code in the page, then send the results to the Web browser.
The distinction here is subtle, but very important. If, for instance, a Web server knows how to interpret Perl code all by itself, it doesn’t have to waste the time and resources involved in launching the code as a separate program to generate a dynamic Web page with it. In addition, the Web server can do smart things like realizing that a particular dynamically-generated page will change at most every 5 minutes, so if it runs some Perl code in response to a request from one Web browser, it’ll keep a copy of the resulting HTML on hand for 5 minutes so that it doesn’t have to re-run that same Perl code if another identical request is received within that time.
Resources:
- See descriptions of individual scripting languages below