Manage cookies that are used for advertising, such as ad personalization, remarketing, and ad effectiveness analysis.
2.4.3.15. PHP code in HTML files does not work, or instead of opening site, download.php file is downloaded.
The problem may occur when you attempt to override files that should be processed by PHP in the .htaccess file as follows:
RemoveHandler .html .htm
AddType application/x-httpd-php .php .htm .html
This construction can only be used when PHP is running in mod_php mode. On our servers, PHP operates in a different — fastcgi, so handlers need to be overridden differently.
To have PHP additionally process files with the .html extension:
- Open the "Site settings" section.
- In the "PHP files" field, add
.htmland save the changes. - Wait approximately 10-15 minutes and check for the issue.
(1)