kb: technical
Symptoms
- PHP 8.2 is selected for the domain example.com in Plesk > Domains > example.com > PHP Settings,
- Accessing the phpinfo() page via Domains > example.com > PHP Setting page displays PHP version 7.4 instead of the configured version.
Cause
The behavior occurs because of custom PHP handler directives defined in the domain’s .htaccess file. These directives override the PHP version configured in Plesk and force the use of a different handler.
Resolution
- Log into Plesk.
- Open the .htaccess file in Domains > example.com > Files.
-
Locate the section that defines the PHP handler, for example:
CONFIG_TEXT: <IfModule mime_module>
AddHandler application/x-httpd-ea-php74 .php .php7 .phtml
</IfModule>Comment out these lines so they are no longer applied:
CONFIG_TEXT: #<IfModule mime_module>
#AddHandler application/x-httpd-ea-php74 .php .php7 .phtml
#</IfModule> - After saving the changes, the domain will use the PHP version configured in Plesk, and the phpinfo() page should reflect PHP 8.2 as expected.
Comments
Please sign in to leave a comment.