Different php.ini for 2 version php?

Royal Flash

Verified User
Joined
Aug 19, 2012
Messages
27
Hello.

I install 2 php (custombuild 2.0):
Code:
php1_release=5.5
php2_release=5.3
php1_mode=suphp
php2_mode=suphp

When I connect php 5.3 with a .htaccess, phpinfo() print:

Code:
PHP Version 5.3.27
Configuration File (php.ini) Path	/usr/local/php53/lib
Loaded Configuration File	/usr/local/php53/lib/php.ini

When I start php 5.5 - (delete .htaccess), phpinfo() print:

Code:
PHP Version 5.5.1
Configuration File (php.ini) Path	/usr/local/php55/lib
Loaded Configuration File	/usr/local/[B]php53[/B]/lib/php.ini

How can specify for php 5.5.1 php.ini path /usr/local/php55/lib/php.ini?
 
Thanks for reporting the issue, the path is set in /etc/httpd/conf/extra/httpd-suphp.conf.
 
Thansk for replay.

Please help with the decision of such questions:

1. Correct code for /etc/httpd/conf/extra/httpd-suphp.conf? My suphp.conf:

Code:
<IfModule mod_suphp.c>
<FilesMatch "\.(inc|php|php3|php4|php44|php5|php52|php53|php54|php6|phtml|phps)$
AddHandler x-httpd-php53 .php53
AddHandler x-httpd-php55 .inc .php .php3 .php4 .php5 .php55 .phtml
</FilesMatch>
<Location />
suPHP_Engine on
suPHP_ConfigPath /usr/local/php53/lib/
suPHP_AddHandler x-httpd-php53
suPHP_AddHandler x-httpd-php55
</Location>
</IfModule>

2. When i change in DA User Level -> Domain Administration -> domain.com: First PHP-php5.3, Second PHP-php5.5, default is still 5.5. Changing versions php in DA does not work.

3. How to use Second PHP for user? I place .htaccess in /home/USERNAME/:
Code:
<FilesMatch "\.(inc|php|php3|php4|php44|php5|php52|php53|php54|phtml|phps|html|htm)$">
AddHandler x-httpd-php53 .php .html .htm .phtm
</FilesMatch>
It is right variant?

I have FreeBSD 8.4, custombuild 1.2 updated on custombuild 2.0
 
1. You may change:
Code:
suPHP_ConfigPath /usr/local/php53/lib/

To:
Code:
suPHP_ConfigPath /usr/local/php55/lib/

2. That is a known issue and it should be solved soon.

3. Yes, that's fine for now.
 
Back
Top