![]() You can then view the settings to ensure they are set correctly. You can check to see if any changes you made took place by placing a phpinfo page in the folder area you are working on. Using the MultiPHP Manager to Change the PHP Version Otherwise, you can contact tech support to have them restore the specific php.ini version to the folder you need it in. suPHP_ConfigPath /usr/local/lib suPHP_ConfigPath /opt/php52/lib suPHP_ConfigPath /opt/php54/lib Note! If you need an older version of the php.ini file restored to a specific directory, you can specify the path to whatever version you are looking for like the following. This allows a php.ini to be stored in the subdirectory, particularly for your PHP version in that directory. To point your domain to a php.ini in a subfolder you would do the following: suPHP_ConfigPath /home/USER/public_html/foldername In this case, the path goes to the public_html directory. The following code will direct the server to the particular php.ini file. This could cause a newer php.ini version to be used instead of the older php.ini version, which can cause an issue in some cases. htaccess file has an invalid PHP handler, the PHP file will download instead of executing. ![]() If there is no php.ini specific to the version of PHP you are using in the directory where the version code is added, the server will use the default php.ini. Why is a download prompt appear upon accessing my website Answer. htaccess, you may need the php.ini for that particular version uploaded to the directory and the recursive path added in order for the correct version of the php.ini to load. Important! If you have PHP errors after adding the. htaccess your site in that directory will use that version of PHP. Once you add the appropriate version code to your. php5 PHP 7.4 # Use PHP 7.4 as defaultĪddHandler application/x-httpd-php74. Go ahead, click on the WordPress logo under the auto-installer. Based on your hosting service provider, you’ll find different auto-installers, such as Softaculous, Fantastico, QuickInstall, and so on. In your cPanel, you’ll notice the Autoinstaller. php5ĪddHandler application/x-httpd-php73. Step 2: Click On the WordPress Auto Installer. php5 PHP 7.2 # Use PHP 7.2 as defaultĪddHandler application/x-httpd-php72. php5 PHP 7.1 # Use PHP 7.1 as defaultĪddHandler application/x-httpd-php71. php5 PHP 7.0 # Use PHP 7.0 as defaultĪddHandler application/x-httpd-php70. php5 PHP 5.6 # Use PHP 5.6 as defaultĪddHandler application/x-httpd-php56. php5 PHP 5.5 # Use PHP 5.5 as defaultĪddHandler application/x-httpd-php55. php5 PHP 5.4 # Use PHP 5.4 as defaultĪddHandler application/x-httpd-php54. PHP 5.3 # Use PHP 5.3 as defaultĪddHandler application/x-httpd-php53. Below is the code you need for each PHP version. htaccess of the directory you want to change the PHP version for. Using Multiple PHP Versionsĭepending on what version of PHP you want to use, you will need to place the following code in the. This will make the specific directory use the System’s default PHP version. htaccess: # Use system PHP5 as defaultĪddHandler application/x-httpd-php5. To use the system default PHP, use the following in. Here is how to use any combination of other PHP versions in any directory when web hosting with PHP. For example, you can have PHP 5.4 for the site in public_html and then use PHP 5.2 in a subdirectory. My htacces file is looking same as the normal htaccess file looks.When using different software on one account, you may need to use one version of PHP while running multiple PHP versions on different domains. If by chance you are still having an issue, feel free to post a comment at the bottom of this page with more information, and I'll be happy to look into this further. I'll assume you were able to resolve this issue, as I tested in several browsers and was not able to replicate the problem. htaccess files could be affected files in the rss folder: What this means, is that if your rss folder is located here: One of the things to keep in mind is that. I assume that you were able to resolve the issue? I tested the URL you provided, but I was not able to replicate the issue. Most of the time, the problem is due to conflicting code in your. I've seen this issue a few times in the past. It differs based on your cPanel username and based on the location of your cPanel account on the actual server, so make sure you get your correct path from the. Whenever I try to open a php file the browser tries to download it instead of loading it normally.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |