Enter promo code HALFMANAGED at checkout for 50% off your first month’s bill on any managed service!
50% off managed hosting with code HALFMANAGED

Need help? We may have the answer for you already!

How to Set the PHP Version per Folder?

Do you have a single domain or wish to use different PHP versions per folder? Do you have an installed PHP 5.x software in a folder/blog and want to use a PHP 7.x instead? If so, you can do this using cPanel and the .htaccess file.


1. Log into your cPanel account.


2. In the Software section, click on the MultiPHP Manager icon.


3. Assume that we are new to this, and the first thing we will need to do is to get the code generated by cPanel.

4. Scroll down to the end of the page, select your domain from the left side, and see the PHP Version option. With a drop-down list on the right side. Select the appropriate PHP version from the drop-down menu and click the Apply button.


5. Now open the /public_html/.htaccess file in the cPanel File Manager or in your FTP client, and you will find the code generated by cPanel.


6. After you copy the code, you will wish to set the PHP version to version 7 in the folder/forum, which means you will need to create a .htaccess file in the folder /forum/ and paste the code generated in the previous step in it.

7. Congratulations, now your folder/forum uses PHP 7, and if you wish to set any other folder to use the same version of PHP as well, you will only need to copy the code from the .htaccess file and paste it into that folder.


Reset your PHP version from your main domain. If you wish to use a different PHP version on any folder, you will need to follow steps 5 and 6, generate the code, copy that code from /public_html/.htaccess and paste it into any folder where you wish to set your selected PHP version.

News @ RackSRV

Customer Feedback

  • If you want A friendly, professional service you will not find better than RackSRV. I feel fortunate that our clan found Jon to host out Dedi box. We have visitors from all over Europe, and as far as the US playing on our servers and all say they have a good gaming experience , which is testiment to the service offer...

    Clive - WarZone Gaming
  • I have rented with RackSRV for quite some time now and I have had nothing but a good experience with them. Over the years I have used many hosts, but RackSRV are the very best

    Christer Emil
  • Highly recommend RackSRV, We have been a customer for over 6 years with no issues. They has been extremely accommodating to all our needs, Our project has come to an end so we've had to cancel service, and even then they have helped massively in the termination of service and handover of data. Will remember th...

    Stuart - About IT Ltd
  • RackSRV have been the most efficient, professional dedicated hosting company we at WBW Gaming & Social Network have used. After 3 years of problems with hosting we came to RackSRV and never looked back. If you require a server that is like no other, if your business needs great support, competitive prices and an...

    Andrew - ASCO LIMITED
  • One of the best companies that I've ever dealt with, and I've been through a few. When getting support, you often speak to the owner himself and any issues are resolved very quickly. Not to mention that the prices simply cannot be beaten, and can be tailored to your specifications and price range. Excellent ...

    Peter
  • The service is very good. We have no issues with the support. They are always on-time to provide assistance.

    Rommel - PnD Hongkong Limited
  • Having hosted my social networking site with several other hosting companies in the past and having experienced varying levels of service and support I must say that the support and service I have received from Jon and Lee at Racksrv is undoubtedly the best by far. My site's requirements are very specific, running on ...

    Mark - Phenomenon Communications Ltd
0