smarty静态实验表明,网络上是错的~呵呵
更新时间:2006年11月25日 00:00:00 作者:
复制代码 代码如下:
<?
require_once("Smarty/libs/Smarty.class.php");
$smarty = new smarty();
$smarty->templates_dir="templates";
$smarty->templates_c_dir="templates_c";
$smarty->left_delimiter="<{";
$smarty->right_delimiter="}>";
$smarty->assign("title","你成功了");
$smarty->display("test.html");
$content=$smarty->fetch("test.html");
$fp=fopen("ok.html","w");
fwrite($fp,$content);
fclose($fp);
?>
require_once("Smarty/libs/Smarty.class.php");
$smarty = new smarty();
$smarty->templates_dir="templates";
$smarty->templates_c_dir="templates_c";
$smarty->left_delimiter="<{";
$smarty->right_delimiter="}>";
$smarty->assign("title","你成功了");
$smarty->display("test.html");
$content=$smarty->fetch("test.html");
$fp=fopen("ok.html","w");
fwrite($fp,$content);
fclose($fp);
?>
相关文章
PHP 命令行工具 shell_exec, exec, passthru, system详细使用介绍
PHP 为执行外部命令提供大量函数,其中包括 shell_exec()、exec()、passthru() 和 system()。这些命令是相似的,但为您运行的外部程序提供不同的界面。2011-09-09
基于yaf框架和uploadify插件,做的一个导入excel文件,查看并保存数据的功能
本文主要介绍了基于yaf框架和uploadify插件,做的一个导入excel文件,查看并保存数据的功能的思路与方法。具有很好的参考价值,下面跟着小编一起来看下吧2017-01-01


最新评论