In your cPanel, you can change PHP version, go in section Softwares, icon 'Select PHP version'
(If you do not see icon 'Select PHP Version', this means that you are on a cPanel server without Cloudlinux, see explanation at the bottom of this article.)
Observe the current PHP version, default is version 7, as it is the most performant with opcache server based, stable, secure. This PHP selector from Cloudlinux apply one same PHP version to all domains of your cPanel account.
NB : If you use NGINX PHP-FPM : see our dedicated article, PHP selectors from Cloudlinux and cPanel do not work
How to switch PHP version ?
See dropdown menu just below, choose version, and click "Set as current", the version will apply to all domains of your account.
You can also personalize by choosing PHP extensions per PHP version, choose/remove what you need, save at bottom.
Here is the written list of the available php extensions :
apcu, bcmath, brotli, dba, dbase, dom, eio, enchant, fileinfo, gd, gender, geoip, geos, gmagick, gnupg, grpc, http, igbinary, imagick, imap, inotify, interbase, ioncube loader, json, ldap, luasandbox, lzf, mailparse, mbstring, memcache, memcached, mongodb, mysqli, mysqlnd, nd mysqli, nd pdo mysql, newrelic, oauth, oci8, odbc, opcache, pdf, pdo, pdo dblib pdo firefebird, pdo mysql, pdo oci, pdo odbc, pdo sqlite, pdo sqlsrv, pgsql, phalcon3, phar, posix, propro, pspell, raphf, redis, snmp, soap, sockets, sodium, sourceguardian, sqlsrv, ssh2, stats, swool, sysvmsg, sysvsem, sysvshm, tideways, tidy, timzonedb, trader, uploadprogress, uuid, vips, wddx, xdebug, xmlreader, xmlrpc, xmlwriter, xsl, yaf, yaml, zip, zmq
You can also put a different PHP version for 1 or more domains of your account by adding a piece of code in the .htaccess to the root of the relevant website folder :
1. If you want to put PHP56 for a website instead of using the default PHP7 version that is configured for the whole account, add this to the .htaccess file :<FilesMatch "\.(php4|php5|php3|php2|php|phtml)$">
To customize your php.ini, you can only do this by clicking on the right top"Switch to PHP settings" : click on the value of the setting you wish to update and save. At each change of PHP version, you must set/verify again these values to same as previously. See our article for details : https://support.yoorshop.hosting/knowledgebase/115/Can-I-customize-my-phpini-.html
activating memcache in Prestashop require to add server 127.0.0.1
activating memcache in Wordpress require to add extension WP-FFPC or similar
For cPanel server without Cloudlinux (custom hosting and HA offers)
In your cPanel, section Softwares, you have :
- icon 'MultiPHP manager' for choosing php versions per domain basis
- icon 'MultiPHP ini editor' to customize your php.ini per domain basis
(There is no possibility at your level to choose extension php, you must open a ticket and ask what you need)
We consider that this message sometimes given by scripts and applications for the implementation...
From december 11th 2018 (For HA offers, see old method at bottom) Use your dedicated IP for...
We have 2 types of servers : Cloudlinux-cPanel, and cPanel, the method is different for...
To change master password of cPanel, you must do this from your customer area on...
From July 2018, you can access the SSH terminal directly from your cPanel account (ask us...