| |||
| |||
|
|
|
Home:
Support:
Manual:
CGI:
What Are:
What Are CGI's ? A typical use for CGI is the processing of online forms. When the user fills in the boxes on the form and hits the SUBMIT button, the cgi program specified in the html will be run at the server, and the information in the boxes become available to the program as parameters. The program, being a program, can then do anything the programmer wanted it to do. "cgiemail", for example, is a canned program written in C that gathers up the contents of the input fields on the form and emails them to a specified destination, then sends a WWW page confirming of the action. "imagemap" is another common use for CGI. Here, the X-Y coordinates of the pointer on an image are correlated with a specification table, so that clicking on different parts of the image will result in different links being followed. Other CGIs might ask for a password, check the password, then access a database for requested information. What it does is up to the programmer, but we do ask that the CGIs are reasonable in their usage of CPU time and memory. While we do not require that they be submitted for approval first, out of control programs that hog the CPU will be hunted down and killed by our death robot. Your web server comes configured with a few of the most popular CGI programs used on the web which are discussed here in this manual. They are located in the /www/htdocs/cgi-bin directory. For example, to access the "formmail.pl" program , you would use the following "http://www.yourdomain.com/cgi-bin/formmail.pl". To preserve the integrity of these scripts and the cgi-bin directory, you are not allowed to add new files to this cgi-bin directory. This means any scripts that you create or upload to your web site need to be stored somewhere other than this system cgi-bin. You can create your own directory and call it cgi-local if you wish. This will allow you to keep organized by having all your scripts in one place. You may also upload and run CGI scripts in any directory of your web space as well. |