For more information about Perl, you might want to review the
"Introduction to Perl" by Larry Wall, et al.
Marshall Brain of Interface Technologies has written
"A Quick Introduction to PERL," which is a succinct introduction
for users who already understand programming.
For a more general approach to using Perl to write CGI scripts, see
A Tour of HTML Forms and CGI Scripts, by Sanford Morton.
Morton's document may make a good companion for the document you
are now reading; it covers much of the same material from a different
point of view.
Some knowledge of HTML and HTML forms processing is necessary
before learning to write CGI scripts; for background information
about these topics, see
This tutorial is somewhat specific to writing scripts within the
environment provided by the Unix operating system, in general,
and on systems operated by Academic Computing Services (ACS) at
The University of Kansas (KU), in particular.
The general principles will hold for any environment providing Perl,
but the specifics may change.
Users of ACS systems usually store their HTML documents in
a directory called
public_html in their login directories.
The Perl scripts they create are stored in a subdirectory of
public_html called cgi-bin.
Programs in this directory can be run as CGI scripts on most Unix systems
operated by Academic Computing Services (ACS) at the
University of Kansas (e.g., FALCON, EAGLE, LARK, RAVEN, etc.).
As mentioned earlier, this tutorial presents an erector set of
Perl program fragments for performing tasks commonly used with
CGI scripts.
These building blocks allow you to
Most readers will find it useful to review the entire tutorial to
get the big picture and then concentrate on those building blocks
which they want to use in their own CGI scripts.
Perl may be used to return an HTML document by using a program like
Recommended background
Writing Perl CGI scripts without forms
Note that these building blocks are useful for building scripts that
work both with and without forms.
Since scripts that work without forms are simpler, we start with
those and then enhance those scripts to work with data supplied
by forms.
Sending an HTML document to the user