In the cPanel/WHM Server, EasyApache 4 interface allows you to install, configure, update, and validate your Apache, PHP and other services on your server. cPanel based server supports multiple versions of PHP. This cPanel interface allows you to assign different versions of PHP to each of your domains. You can find EasyApache 4 within the Web Host Manager, or “WHM” for short.
The below-mentioned steps indicate how you can install the PHP version and PHP Extensions from the WHM Panel:-
Step 1# Login to WHM Panel and access EasyApache 4 by using the search bar in the top left of WHM or going to WHM Home >> Software >> EasyApache 4
Step 2# Once you have navigated to EasyApache 4, you can see “Currently Installed Packages” section, click on the button “customize”
Step 3# Click on the “PHP Versions”
Step 4# In the PHP Versions menu, you can select all required PHP versions, which you wish to install. WHM/cPanel Server Panel will automatically check for PHP Extensions currently being used by other versions of PHP. More than likely these PHP Extensions are currently being used by one of your domains, and because of this, E2E Networks recommend selecting the PHP x.x and Extensions button when selecting a PHP Version. After you have selected the versions you wish to install on your server, click “Next”.
Important Note:- E2E Networks would highly recommend using the most recent version of PHP as PHP version 5.6 and 7.0 will no longer have security updates as of January 1, 2019. For more details on supported PHP versions, you can go with this weblink - https://www.php.net/supported-versions.php
Step 5# Next go to the “PHP Extensions” menu, you can select all PHP extensions you require.
In cPanel, EasyApache has already selected suggested PHP Extensions that existed on previously installed versions of PHP on your server by default. For example, To install PHP Extensions, in the Search field, type your required PHP extensions name like “iconv”
Click on the toggle button next to the PHP version that you wish to install a PHP extension for your domain.
Step 6# Once you have finished your selections, click on Next or Review.
Step 7# Finally click on the “Provision” button
Step 8# Once the installation is finished, you will receive a message:- “The provisioning process is complete”. Click on the “Done” button to finish this installation task.
Cheers !! Now you have installed PHP versions & PHP Extensions using EasyApache on cPanel/WHM Server.
After installation of Multiple PHP versions, you have to assign the required PHP version to your Domain. In the below-mentioned steps, we have guided you to change the PHP version for your cPanel accounts or Domains.
Step 9# cPanel’s MultiPHP Manager supports you to manage cPanel accounts or hosted Domains PHP configuration on a per-domain basis. You can also set the system’s default Global PHP Version for all cPanel accounts, enable PHP-FPM globally or per domain, and adjust PHP-FPM pool options on this section.
To define PHP Versions for your Domain, Go to WHM >> Software >> MultiPHP Manager or You can search PHP at the left-hand corner search bar and click on “MultiPHP”
Step 10# Search for the domain or accounts you wish to alter and click on the drop-down menu located in the PHP Version column.
Step 11# Lastly choose your required PHP version and apply it for your Domain.
Try our cPanel Integrated Cloud Servers here