in reply to Re: CGI error with simple script
in thread CGI error with simple script
As ptum has already said, you need to print the HTTP header first. CGI.pm doesn't export the header subroutine into your namespace by default though, so you'll need to do one of these three things:
use CGI; print CGI::header();
use CGI qw(:standard); print header;
use CGI; my $q = new CGI; print $q->header;
Take a look at perldoc CGI as well, it contains a lot of functions which will make writing your dynamic pages easier.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: CGI error with simple script
by rndmtxt (Initiate) on Jan 10, 2006 at 18:52 UTC |