Home / web hosting / How to edit php.ini on shared servers from ftps

How to edit php.ini on shared servers from ftps

With the help of PHP Selector implemented on our shared servers, you can easily modify basic PHP settings in your cPanel > section Software/Services Select PHP Versionmenu.
However, advanced PHP settings are missing from PHP Selector tool, and they need to be manually configured in the php.ini file. Feel free to download php.ini for different PHP versions below in the Attachments section at the end of the guide.

When all updates are completed, make sure that you rename the file to php.ini. In order for the php.ini to work add Lsapi_phpini directive.

To find out the current PHP version and configuration, refer to the below steps.

How to check PHP version and configuration

There are two ways to check PHP version set for the account. By default, we have PHP 5.6 set on our shared servers.
To check what PHP version is selected for your account go to cPanel Software section > Select PHP versionmenu:

You will see the current PHP version above PHP extensions:



Another way to check PHP version is PHPinfo() function, commonly used to check the current state of PHP configuration. It can also be used for debugging purposes as it contains all EGPCS (Environment, GET, POST, Cookie, Server) data.

To run the function, follow the steps below:

for cPanel Basic theme
for cPanel Retro theme

for cPanel Basic theme:

1. Log into your cPanel account, go to Files section > File Manager menu:

2. Navigate to public_html directory, click on New Fileand create a phpinfo.php file:

3. Find the newly created file in the list and click on Code Editor:

4. Add the lines of the code provided below to the file and click on Save Changes:

<?php
phpinfo();
?>

5. To see the detailed information about PHP configuration of your account, open http://yourdomain.com/phpinfo.php link in your browser, replacing yourdomain.com with your main domain name.

NOTE: For security reasons, do not forget to delete the file once you check all the necessary information.

for cPanel Retro theme:

1. Log into your cPanel account, go to the section Files File Manager menu:

2. Navigate to the public_html directory, click on New Fileand create a phpinfo.php file:



3.Find the newly created file in the list and click on Code Editor:

4. Add the lines of the code provided below to the file and click on Save Changes:


<?php
phpinfo();
?> 

5. To see the detailed information about PHP configuration of your account, open http://yourdomain.com/phpinfo.php link in your browser, replacing yourdomain.com with your main domain name.

NOTE: 
For security reasons, do not forget to delete the file once you check all the necessary information

About solomon121

Check Also

Step by step on how to register hosting account 2018 editions

Good day my people here, Today i will guilde you on how to get started …

Leave a Reply

Your email address will not be published. Required fields are marked *