Server-side scripting

From Free net encyclopedia

Server-side scripting is a web server technology in which a user's request is fulfilled by running a script directly on the web server to generate dynamic HTML pages. It is usually used to provide interactive web sites that interface to databases or other data stores. This is different from client-side scripting where scripts are run by the viewing web browser, usually in JavaScript. The primary advantage to server-side scripting is the ability to highly customize the response based on the user's requirements, access rights, or queries into data stores.

In the "old" days of the web this was almost exclusively performed using a combination of C programs, Perl scripts and Shell scripts using the Common Gateway Interface (CGI). Those scripts were executed by the operating system, and the results simply served back by the web server. Nowadays, these and other online scripting languages such as ASP and PHP can often be executed directly by the web server itself or by extension modules (e.g. mod_perl or mod_php) to the web server. Either form of scripting (i.e. CGI or direct execution) can be used to build up complex multi-page sites, but direct execution usually results in lower overhead due to the lack of calls to external interpreters.

Dynamic websites are also sometimes powered by custom web application servers, for example the Python "Base HTTP Server" library, although some may not consider this to be server-side scripting.

List of server-side scripting technologies

  • ASP
    • Microsoft designed solution allowing various languages (though generally VBscript is used) inside a HTML-like outer page, mainly used on Windows but with limited support on other platforms.
  • ASP.NET
    • Despite sharing a name with conventional ASP this system encourages the programmer to use an event driven model with controls and uses code written in the .NET bytecode compiled languages rather than scripting languages.
  • ColdFusion
    • Cross platform tag based commercial server side scripting system.
  • JSP
    • A Java-based system for embedding code in HTML pages.
  • SSI
    • A fairly basic system which is part of the common apache web server. Not a full programming environment by far but still handy for simple things like including a common menu.
  • Perl
    • Not specifically designed for web scripting but still often used either through CGI or a special apache module.
  • Python
    • Another language commonly used through CGI.
  • Tcl
    • Another language sometimes used through CGI.
  • PHP
    • Common opensource solution based on including code in its own language into an HTML page.
  • Server-side JavaScript
    • A language mostly used on the client side but also occasionally on the server side.
  • VBScript
    • Used for both server-side and client-side scripting, but primarily server-side. This version of Visual Basic is supported primarily on Microsoft platforms.

See also

th:Server-Side Script xx