Chapter 21. CGI Scripting and Alternatives
When a web browser (or any other web client) requests a page from a web server, the server may return either static or dynamic content. Serving dynamic content involves server-side web programs to generate and deliver content on the fly, often based on information stored in a database. The long-standing web-wide standard for server-side programming is known as CGI, which stands for Common Gateway Interface:
In other words, the server's role is that of a gateway between the client and the other program. The other program is called a CGI program, or CGI script.
This chapter assumes familiarity with HTML and HTTP. For reference material on these standards, see Webmaster in a Nutshell, by Stephen Spainhour and Robert Eckstein (O'Reilly). For detailed coverage of HTML, I recommend HTML & XHTML: The Definitive Guide, by Chuck Musciano and Bill Kennedy (O'Reilly). For additional coverage of HTTP, see the HTTP Pocket Reference, by Clinton Wong (O'Reilly).