seperate CGI

From: Date: Fri, 07 Jan 2000 05:39:31 +0000
Subject: seperate CGI
Groups: php.version4 
Request: Send a blank email to php-version4+get-8967@lists.php.net to get a copy of this message
I am on a webserver that has php installed as a module. I would like to compile the 4beta3 source as a cgi and just use #!/path/to/php at the top of my scripts. That way I can do all my own configs and not bug anyone at the host. Here is what I tried: <---------------------------------------- #!/usr/bin/perl print "Content-Type: text/html\n\ntest"; ----------------------------------------> was a perl file pl.cgi <---------------------------------------- #!/home/me/php <? echo "test"; ?> ----------------------------------------> was the php file myscript.cgi and then these were the shell commands i used <---------------------------------------- [me@server directory]$ ./myscript.cgi Content-Type: text/html test [me@server directory]$ ./pl.cgi Content-Type: text/html test [me@server directory]$ ----------------------------------------> both of them worked at the shell fine then, when executing with apache the pl.cgi worked and the other one gave me the message: "No Input File Specified.", not an apache error, just a message in my browser from nowhere. So, I tried it on my local server, and the perl script worked, but I keep getting "premature end of script headers" errors in my apache log for the php script, even though they both work perfectly as a standalone executable at the shell. The CGI's may have different compilation configurations, but I can't see how that would matter. If someone could help me out I would really appreciate it. Thanks. -Jeff Davis

« previous php.version4 (#8967) next »