标签: php html haml preprocessor
是否有可能使HAML预处理程序对I.E.无效。 <?= $test ?>并按原样打印出来?然后将HTML文件转换为PHP文件以用作模板。
<?= $test ?>
答案 0 :(得分:0)
如果在扩展名为.html的页面中使用代码,则它将直接按原样显示PHP代码。
.html
PHP
但是对于.php文件,可以使用htmlentities。例如:
.php
echo htmlentities('<?= $test ?>');