Re: running php as cgi script

From: Date: Sun, 17 Nov 2002 20:55:10 +0000
Subject: Re: running php as cgi script
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-124823@lists.php.net to get a copy of this message
Well, I've got a few test scripts to run by following the suggestions from the posts. There's just one thing that's not quite right yet. The "#!/usr/bin/php" line appears at the top of the page. For instance when I run the following script from the cgi-bin: #!/usr/bin/php <? phpinfo(); ?> The phpinfo page comes up fine, but "#!/usr/bin/php" appears at the top. This happens whether I call the script "test.php" or "test.cgi". Appreciate any tips on how to get rid of it or why it's there. Thanks, SW On Saturday 16 November 2002 12:17 am, you wrote: > I'm not intending to run the script from the shell. What I am trying to do > is encrypt emails with Gnupg. The problem is Gnupg runs as my user name > and php runs as nobody. So I'm trying to run a php script as cgi to > deliver the data to Gnupg since a cgi script will run as my username. I am > using a perl script right now and it works, but the rest of the application > is in php, so its causing some me some design difficulties. > I'm going to try some the suggestions posted and see if I can get it > working. Thanks, > SW > > On Friday 15 November 2002 11:04 pm, you wrote: > > Joseph, I think he's trying to run the script from the shell--in which > > case it looks okay to me (besides perhaps a terminating semicolon on the > > last line) > > > > Marco

« previous php.general (#124823) next »