Practical and Useful Information For Enhancing Your Site

CGI/Perl Scripts

First, let's correct a common misconception: CGI is not a programming language; you don't write programs in CGI. CGI stands for "Common Gateway Interface"; it's a protocol and Perl is a programming language. CGI defines the way in which external programs should communicate with a Web server, and programs that adhere to the CGI protocol are referred to as CGI Programs or CGI Scripts. The majority of CGI programs are written in a language called Perl and, for reasons we don't fully understand, CGI programs written in Perl are referred to as CGI Scripts.

While HTML/XHTML, CSS, and JavaScripts control the look and feel of a Web page, it often takes CGI/Perl scripts running on the server to make the page functional. Common features such as forms, forums, and guest books are often controlled by CGI/Perl scripts. Check with your system administrator to determine if you can run CGI scripts on your server. If so, find out where the scripts should be located, whether a wrapper script is required, and get the paths to common server resources such as date, the Perl interpreter, and sendmail.

Hundreds of free CGI/Perl scripts are available from the CGI Resource Index -- everything from access counters, bulletin board messaging systems and guestbooks to Web-based e-mail.