Different PHP Version for a VirtualHost

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

i posted this to a forum, but I think this is the better place to ask.

I have a client who needs hosting for an old CMS that still uses PHP
4.4.x. I know they will have to upgrade eventually, but I need to keep
the site up in the meantime. 

I have managed to compile and install php 4.4.9 as cgi and I try to
configure Apache to use this version for the client's virtual host
only. 

The problem is, it doesn't work. I'm able to configure apache to use my
php4-version for ".php4"-files, but not for ".php". It always uses the
default version. I tried using AddType and AddHandler and also to use
RemoveTYpe/RemoveHandler before. I tried moving various bits
to .htaccess instead, but it just won't work.  



My simplified config looks like this:

<VirtualHost 12:34:56:78:80>
    ServerName www.domain.com

    DocumentRoot /home/user/public_html
    ErrorLog /home/user/log/error.log
    CustomLog /home/user/log/access.log combined

    <Directory /home/user/public_html>
            Options -Indexes FollowSymLinks MultiViews
            AllowOverride All
            Order allow,deny
            Allow from All
     </Directory>

    DirectoryIndex index.html index.php

    <directory "/var/www/php4">
        AllowOverride None
        Options +ExecCGI +FollowSymLinks
        Order allow,deny
        Allow from all
    </directory>

    ScriptAlias /php4cgi /var/www/php4
    Action php4-cgi /php4cgi/php
    AddType php4-cgi .php4 .php

</VirtualHost>


Any ideas what to try next? Or workarounds?


regards,

Stefan



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux