Increasing File Upload Limit in cPanel Using Select PHP

Shipon

Last Update 7 เดือนที่แล้ว

In cPanel, you can manage various settings for your website, including PHP configurations. Sometimes, you might need to increase the file upload limit to accommodate larger files for your web applications. You can achieve this by using the "Select PHP Version" tool in cPanel. This knowledge base will guide you through the process of increasing the file upload limit using the "Select PHP Version" feature.

Note: Before making any changes, it's essential to ensure that you have the necessary permissions and access to cPanel on your hosting provider's platform.

Step 1: Access cPanel

  1. Log in to your cPanel account using your username and password.
  2. Once logged in, you will see a variety of icons and options. Look for the "Software" section, and within that, locate and click on "Select PHP Version."

Step 2: Select PHP Version

  1. In the "Select PHP Version" tool, you will see a list of available PHP versions. The currently active version is displayed at the top.
  2. To change the PHP version, use the drop-down menu and select a different version. Make sure you choose a version that is compatible with your website and applications.

Step 3: Adjust PHP Options

  1. After selecting the desired PHP version, click the "Set as current" button.
  2. Once the PHP version is set, click on the "Switch to PHP Options" link.

Step 4: Increase the File Upload Limit

  1. In the "PHP Options" section, look for "upload_max_filesize" and "post_max_size." These values determine the maximum file size that can be uploaded and processed by PHP.
  2. Click on the current values for "upload_max_filesize" and "post_max_size" and update them to your desired limit. It's important to set both values to the same limit to ensure consistency.
  • For example, to set a 50MB upload limit, you would enter "50M" for both "upload_max_filesize" and "post_max_size."

Step 5: Save Changes

After adjusting the values, scroll down and click the "Apply" button to save your PHP configuration changes.

Step 6: Verify Changes

To ensure that the changes have taken effect, you can create a test script that displays the current PHP configuration. This can be done by creating a PHP file with the following content:
Upload the test script to your website and access it through a web browser. You should see the updated values for "upload_max_filesize" and "post_max_size" reflecting the changes you made.

Step 7: Test File Upload

To confirm that the file upload limit has been increased successfully, attempt to upload a file that exceeds the previous limit. If the upload is successful, the process is complete.

By following these steps, you can increase the file upload limit for your web applications using the "Select PHP Version" tool in cPanel. Remember to choose a suitable PHP version and ensure that your server's resources can support the increased upload limit. If you encounter any issues, it's recommended to consult with your hosting provider or system administrator for further assistance.

Was this article helpful?

1 out of 1 liked this article

Still need help? Message Us