note 43998 added to security.cgi-bin
| From: | martelli at geoserve dot com dot br | Date: | Mon, 12 Jul 2004 04:25:51 +0000 |
| Subject: | note 43998 added to security.cgi-bin | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-73077@lists.php.net to get a copy of this message | ||
PHP CGI with VirtualHosts.
This is what I found out while trying to get php to work as CGI with Apache VirtualHosts.
By enabling 'force-cgiredirects', you *must*:
1) set 'cgi.fix_pathinfo=1' in php.ini
2) leave doc_root commented out (php.ini also)
If you miss item 1, the apache logs will show 'unexpected T_STRING' in the php binary.
If you miss item 2, you'll only see 'No input file specified.', instead of the
expected output.
You can then turn on the php support for a particular vhost by defining:
Action php-script /cgi-bin/php
inside the corresponding <VirtualHost> directive.
----
Manual Page -- http://www.php.net/manual/en/security.cgi-bin.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+43998
Delete -- http://master.php.net/manage/user-notes.php?action=delete+43998&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+43998&report=yes
Search -- http://master.php.net/manage/user-notes.php