Sample CGI Code
This is a C++ module that contains utilities to generate and parse
I only use the generation utilities these days (see cgi.h).
This is the header for the
Writing a cgi program entirely in PHP
Writing a cgi program entirely in Python
Debugging a script
To test a script from the command line do the following (assumes that
POST is supported by the script):
- perl adduserPL.cgi username=susan password=1234
You should see the output on the screen. To save to a file, do:
- perl adduserPL.cgi username=susan password=1234 > out.html
- Now, edit out.html to remove the top 2 lines of http.
Then, out.html should be viewable by a browser. If it isn't you have an
html syntax error.