View Single Post
  #3  
Old 12th December 2006, 22:04
Sid Sid is offline
Junior Member
 
Join Date: Nov 2006
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

In httpd.conf:
Code:
ScriptAlias /php4-cgi "/usr/lib/cgi-bin/php4"

AddHandler php-script .php4
Action php-script /php4-cgi
for .php4 files to be parsed with php4-cgi

a sample of a vhost config:
Code:
<VirtualHost *:80>
        ServerAdmin some@email.org
        ServerAlias domain www.domain
        ServerName domain

        DocumentRoot /home/www/domain/htdocs/
                                                                                
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /home/www/domain/htdocs/>
                Options -Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
                php_admin_value open_basedir /home/www/domain
        </Directory>

<Directory "/usr/lib/cgi-bin/php4">
php_admin_value open_basedir /home/www/domain
</Directory>

        ScriptAlias /cgi-bin/ /home/www/domain/cgi-bin/
        <Directory "/home/www/domain/cgi-bin">
                AllowOverride None
                Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>

        ErrorLog /home/www/domain/log/error.log
        LogLevel warn
        CustomLog /home/www/domain/log/access.log combined
        ServerSignature On
</VirtualHost>
The part <Directory "/usr/lib/cgi-bin/php4">
php_admin_value open_basedir /home/www/domain
</Directory> was just added for testing but has no effect on php4-cgi...
Reply With Quote