David T-G wrote:

Peter --

...and then Peter Risdon said...
% % David T-G wrote:
% % > bash-2.05a$ /usr/local/bin/php -v
% > PHP 4.3.4 (cli) (built: Jan 6 2004 15:27:52)
% % You probably need the cgi version - not the command line one you % actually have.


Ooohhhhhhhhhhh... Ouch. So there are *three* possible PHP compiles:
module, CGI, and CLI?



So far as the php binary in /usr/local/bin is concerned there are two - cli and cgi. The module consists of different files (see the AddModule and LoadModule bits of httpd.conf). You can have both (I have made that my standard build for multi-homed machines) but need to muck about a bit for this.


OK. To save us the cost of rebuilding at this host, is there any way to
pass args to the CLI version of the script running as a CGI?



You might find you start getting odd problems with http headers if you use the cli version. In general you're better off using the cgi one. But you can get this by recompiling but not installing php cgi, then copy the php executable to, say, /usr/local/bin/php-cgi and prefacing your scripts with this in the shebang. That would mean zero disruption for users on the machine.



Peter.


Thanks & HAND

:-D



-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to