Skip to main content.
home | support | download

Back to List Archive

RE: Help with Scripts -Reply

From: Steve van der Burg <steve.vanderburg(at)not-real.LHSC.ON.CA>
Date: Fri Jun 25 1999 - 20:12:06 GMT
>>> Matthew S. Wieder wrote:
> I keep getting that same error - the apache error-log
> says that there was a premature end to the header.

>>> David Norris wrote:
> That is usually caused when an error occurs before the
> HTTP headers are sent.  That's one major reason I don't
> like using PERL for generating web content, debugging
> is a nightmare.  Which script is it?
Huh?  That's a web server problem, not a perl problem
(assuming he's reading the errors from the httpd's error log).

Is the web server expecting the script to produce all HTTP
headers?  If it's not, it's still expecting the Content-type
header, so make this the first thing that the script prints:
   print "Content-type:  text/html\n\n";
(assuming that it's spewing HTML).

Matthew, not being able to understand or solve this problem
leads me to believe that you should study CGI a bit (in this
case, that your script must provide at least some of the HTTP
headers that the web server would generate if it were serving
static pages).

...Steve
--
Steve van der Burg
Technical Analyst, Information Services
London Health Sciences Centre
London, Ontario, Canada
Tel:  +1 519 685-8300 x 35559
Email: steve.vanderburg@lhsc.on.ca
 
Received on Fri Jun 25 13:03:47 1999