Categories

How to switch to a different PHP version manually (using cPanel)

George Jones February 9, 2017
Rating: 5.0/5. From 5 votes.
Please wait...

This video tutorial will show you how to switch to a different PHP version manually (using cPanel).

  1. Go to cPanel, open File Manager and choose “Web Root (public_html/www)”.

    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-1
  2. Create a new file (or edit the existing one) called .htaccess

    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-2
  3. To switch to PHP 7.0 add the following line:

    AddHandler application/x-httpd-php70 .php .php5 .php4 .php3
    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-3
  4. In order to view your server configuration information download the info.php script, unzip the archive. Then upload it to the root directory of your hosting server.

  5. Open any web browser, in a browser address bar type your_site_domain_name/info.php and you will see that PHP version was switched to 7.0

    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-4
  6. To switch to PHP 5.6 use the following line:

    AddHandler application/x-httpd-php56 .php .php5 .php4 .php3
    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-5
  7. Go back to your site, then open your_site_domain_name/info.php. You will see that PHP version was changed to 5.6

    How_to_switch_to_a_different_PHP_version_manually_using_Cpanel-6

Feel free to check the detailed video tutorial below:

How to switch to a different PHP version manually (using cPanel)
This entry was posted in General tutorials, Hosting FAQ and tagged cPanel, hosting, php, version. Bookmark the permalink.

Submit a ticket

If you are still unable to find a sufficient tutorial regarding your issue please use the following link to submit a request to our technical support team. We'll provide you with our help and assistance within next 24 hours: Submit a ticket