Hello Friends I am a beginner web developer don’t know much about cPanel and hosting, I have been given a cPanel access by one of my friend the url of cpanel consists of (‘magnesium.cloudhosting.co.uk‘). So Now I have to update the php version of the server that is hosting the site, So Inside the cpanel dashboard, in software options I have an option called Select PHP Version, then I go inside this option and change the php version to 7.0 (previously it was 5.6) and click on set as current php version button and save it. And now I go to server information option in cpanel and check the php version of the server and it shows 5.6, I tried to logout and login again but its not working. So What am I missing here.
Below is my cpanel dashboard snippet if you scroll down you will see there is an software option, inside which there is Select PHP Version option
Here is the inside look of Select PHP Version option
Below is the snippet of server information you can see the php version is still 5.6.
Please help me to update the php version I will provide more information If needed.
3
Answers
Based on the domain name I’m guessing that website is being hosted on a shared server? Lots of website hosts won’t allow you to change PHP version for shared servers although I couldn’t find a guide for your website host.
If you search for your website host + “change PHP version” you might find a step by step guide.
On a shared hosting, you could try modifying .htaccess files to specify the PHP version that you want to use. On a dedicated server, you can follow these steps:
Login and search for “multiphp”. Then click “MultiPHP Manager”.
change php version in multiphp manager
If you are choosing php8.1 then Run the following command
Some other versions
Note: this command will work only after changing the php version using php selector.