in reply to Premature end of script headers error

Your web server configuration may not yet know what to do with cgi files.

Are "Options +ExecCGI", "ScriptAlias'", " AddHandler cgi-script cgi pl", and maybe "UserDir" set? The apache httpd manual has details of how to choose sane settings for those.

(Added) Come to think of it, the "Premature end of script headers" message indicates that httpd is trying to treat your script correctly, so ignore the above. By chance are you uploading the script from a winders box? If so you may have a bogus \r tacked onto the perl path in the splatline. Insert a space and a comment or something to check that.

After Compline,
Zaxo

  • Comment on Re: Premature end of script headers error

Replies are listed 'Best First'.
Re^2: Premature end of script headers error
by imp (Priest) on Jul 02, 2006 at 01:24 UTC
    I tested this on my server and having ExecCGI disabled resulted in the following: Options ExecCGI is off in this directory

    If the AddHandler lines were missing then it would just render as whatever DefaultType is set to.