Summary
In this quick tour of CGI scripting, we have seen that:- A CGI script is a program -- generally a C program or a PERL script.
- On most servers, CGI scripts live in a directory named cgi-bin. The script is executed when the script's URL is requested by a browser.
- Anything that the script sends to STDOUT will be sent to the browser. The string "Content-type: text/html\n\n" should be the first thing sent. After that, anything goes; but typically, valid HTML tags for a valid HTML document are sent.
- Input is sent to the script by creating an HTML form whose ACTION specifies the script's URL.
- When a script receives the data from the form, it has to parse out the different strings and convert all of the modified characters. We saw a simple C program that can perform these tasks. The CGI library for PERL (see the next page) makes the conversion easy for PERL scripts.
For more information, check out the links on the next page.

