在.php页面中包含 .shtml 文件



我想在.php页面中包含.shtml文件。我知道这是可能的,就像我以前做过的那样(尽管我忘记了代码)。请有人帮忙吗?

我建议使用:

include_once('/includes/header.shtml');

你试过吗:

 echo file_get_contents('/includes/header.shtml');
 // or
 echo file_get_contents('includes/header.shtml');

它可能会起作用。

但是我会开始将所有模板转换为任何可用的 php 模板引擎。

最新更新