今天在开发过程中,想要在html中解析php,发现不是语法不正确,而是没有开apache的解析模块。
在Apache中开启步骤:
httpd.conf中添加两行代码:
AddType application/x-httpd-php .html .htm .php .phtml
AddType application/x-httpd-php-source .html .htm .phps
AddType application/x-httpd-php .html .htm
在html中解析php
最新推荐文章于 2024-05-20 09:57:40 发布