fbpx

How to switch to a different PHP version?

cables and ports lowaire digital

SiteGround has implemented a unique server setup that allows each customer to choose which version of PHP to use for his / her account. What is more, the customer can even use different PHP versions for different directories in one and the same hosting account.

 

The PHP versions currently supported are: PHP 5.3, PHP 5.4, PHP 5.5, PHP 5.6, PHP 7.0 and PHP7.1.

 

It is really easy to change PHP versions for your website with a web hosting account with SiteGround. All you need to do is follow those steps:

  1. Log in to cPanel for your account
  2. Go to 1H Software section -> PHP Version Manager
  3. Navigate to the directory you would like to change the PHP version for (note that the change will apply to sub-directories for it as well)
  4. Click on the directory name
  5. Select the desired PHP version and click Save

 

That is all.

 

You can find detailed instructions on how to manually change the PHP version for your account below:

 

Go to cPanel, File Manager and choose “WebRoot (public_html/www)”. There create a new file (or edit the existing one) called .htaccess and add the following line:

 

To switch to PHP 7.1

To switch to PHP 7.0

To switch to PHP 5.6

To switch to PHP 5.5

To switch to PHP 5.4

To switch to PHP 5.3

 

This setting will apply recursively to all of the subdirectories. In case you’d like to have a different version of PHP in a subdirectory, create a new .htaccess file in it with the directive for the desired PHP version in it.

 

If you want to be able to use different PHP versions on a per-folder basis, you can sign up for a hosting account at Lowaire Digital. We offer the best PHP hosting and our support team is ready to assist you with any PHP questions/problems you may have.

Share:

More Posts