我在我们网站的大多数html文件中使用了各种 php 代码。我希望将 html 文件视为 php,因此我已将此行添加到 .htaccess
AddHandler application/x-httpd-php5 .html .htm .php
现在,一切都很好,我的 html 文件评估了 php 代码,我很高兴。然而,我的幸福是短暂的,因为这个解决方案产生了另一个问题。字符编码搞砸了,现在虽然我声明了
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
字符在网站上是这样显示的
c�nd�cerc? 年代??我scad?
我的问题是如何评估 html 文件中的 php 而不会弄乱我的 Html 页面的字符编码。
要求显示代码:
<h1 class="Normal-P"><span class="Normal-C-C0">" Cele </span><span class="Normal-C-C1">3 MARI GREŞELI</span><span class="Normal-C-C0"> pe care majoritatea le fac atunci când încearcă </span></h1>
<h1 class="Normal-P"><span class="Normal-C-C0">să îşi </span><span class="Normal-C-C1">scadă colesterolul în mod natural </span><span class="Normal-C-C0">"</span></h1>
导致这个
单击 pe butonul din stanga jos pentru redare....Asteapt?c�teva secunde p�n? cand acest video se �ncarc?