smarty 模板继承问题

文件 parent.tpl

<html>
  <head>
    <title>this is a title</title>
  </head>
  <body>
    this is a content...
  </body>
</html>

文件 child.php

<?php
  include "init.inc.php";
  
  $smarty->display('extends:parent.tpl|child.tpl');
?>

为什么打开 child.php 不能正常继承,页面显示如下:
{extends file='extends:parent.tpl|child.tpl' extends_resource=true}

阅读 1.7k
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题