摘要:
1,smarty模版中if的用法<?php$root=str_replace("\\","/",dirname(__FILE__));define("ROOT",$root."/");define("DOMAIN","http://localhost/testSmarty");require(ROOT."smarty/Smarty.class.php");$smarty=new Smarty();$smarty->template_dir=RO 阅读全文
摘要:
1,先写一个简单的模版赋值index.php 页面<?php$root=str_replace("\\","/",dirname(__FILE__));define("ROOT",$root."/");define("DOMAIN","http://localhost/testSmarty");require(ROOT."smarty/Smarty.class.php");//引入smarty类$smarty=new Smarty();$smarty 阅读全文