Re: php as CGI and $_POST
| From: | Curt Zirzow | Date: | Fri, 04 Jun 2004 14:29:12 +0000 |
| Subject: | Re: php as CGI and $_POST | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-187632@lists.php.net to get a copy of this message | ||
* Thus wrote David T-G (davidtg-php@justpickone.org):
> Curt, et al --
>
> ...and then Curt Zirzow said...
> %
> % * Thus wrote David T-G (davidtg-php@justpickone.org):
> % >
> % > My code is as simple as
> % >
> % > #!/usr/local/bin/php
> %
> % What does '/usr/local/bin/php -v' show?
>
> Doesn't seem to scary to me:
>
> bash-2.05a$ /usr/local/bin/php -v
> PHP 4.3.4 (cli) (built: Jan 6 2004 15:27:52)
that cli should be cgi.
I'm assuming you compiled php with something like:
configure --with-apxs=/yada/apxs [other options]
What you need to do is recompile php with configure like:
configure --[other options]
Then make will build a cgi binary in sapi/cgi/php, relative to your build
directory. If you want both versions (cgi and cli) you'll have to
manually place the cgi version of php somewhere else than
/usr/local/bin or name it something php_cgi. And then reference
that file in you php script.
Curt
--
"I used to think I was indecisive, but now I'm not so sure."