cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PHP version for folder alone

Being in Linux Hosting, Need to configure one folder alone different PHP version. 

Tried different methods provided across web but it didnt worked. 

 

In htaccess file added below lines one by one. but none worked. 

  • # Use PHP 5.5 as default
    #AddHandler x-httpd-php5-6 .php
    #AddHandler application/x-httpd-php56 .php
    #AddHandler x-httpd-php5-6 .php

 

 

How to configure single folder in different version?

3 REPLIES 3
Anonymous
Not applicable

Re: PHP version for folder alone

Hi,

Why do you need to do this?

I'm not surprised it's not working well. You can select on cPanel 5.4 - 5.5 - 5.6 . 5.4 being the 'native' version.

You should really update or build your site according to this. Or you may run into problems.

Support try their best, but as I was informed ages ago, "sorry but we're not programmers", and that's ok. I had to stick my head in piles of docs and books and RTM!

For the BEST advice head on over to here, the source:

http://php.net

 

Good luck!

Re: PHP version for folder alone

Work is going on for new php version . Planning to update one by one to avoid potential downtime. So kindly suggest a way to have different php version for different addon domain or folder.  This is supported in other hosting provider by adding Handlers . 

 

http://www.inmotionhosting.com/support/website/php-configuration/using-multiple-php-versions-one-acc...

 

Employee
Employee

Re: PHP version for folder alone

Were you leaving the # at the start of your lines in the htaccess? That makes the line a comment.