虚拟主机上配置smarttemplate 最好访问都针对根目录。否则很乱。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 终于好了,谢谢!class.smarttemplate.php<?php /** * 为smarttemplate设置3个真实路径:编译临时文件目录,缓存目录,模板目录 * /home/ka1ijikijq/wwwroot/smarttemplate/tmp/ * /home/ka1ijikijq/wwwroot/smarttemplate/tmp/ * /home/ka1ijikijq/wwwroot/smarttemplate * * @author aiiiq * @today 2:19 05-8-28 */ $_CONFIG = array( smarttemplate_compiled => dirname(__FILE__) . "/tmp/", smarttemplate_cache => dirname(__FILE__) . "/tmp/", cache_lifetime => 600, template_dir => dirname(__FILE__) . "/", ); /** * SmartTemplate Class * * 'Compiles' HTML-Templates to PHP CodeHello_World.php<?php require_once "/home/ka1ijikijq/wwwroot/smarttemplate/class.smarttemplate.php"; // 同样需要绝对路径 $page = new SmartTemplate("Hello_World.html"); $page->assign('TITLE', 'Hello World!'); $page->output();?> PHP连接其它计算机的SQL SERVER zend studio 7.1的ftp链接问题[高分在线等] 【主流】模板系统和技术集锦 mysql按某种条件排序后,怎么取最后一天记录 请教一段代码 请教一个内嵌html语句的问题 phpcms2008sp4采集功能问题 怎么能防止用户不在本站提交资料,而是自己做的一个form往我站内提交呢? ITC(深圳)高薪诚聘 PHP 软件工程师,各位帮忙UP。 小数点后面怎么取两位? 头脑 一台服务器装了SQL 2000和 MY SQL 会有冲突么???
class.smarttemplate.php<?php /**
* 为smarttemplate设置3个真实路径:编译临时文件目录,缓存目录,模板目录
* /home/ka1ijikijq/wwwroot/smarttemplate/tmp/
* /home/ka1ijikijq/wwwroot/smarttemplate/tmp/
* /home/ka1ijikijq/wwwroot/smarttemplate
*
* @author aiiiq
* @today 2:19 05-8-28
*/ $_CONFIG = array(
smarttemplate_compiled => dirname(__FILE__) . "/tmp/",
smarttemplate_cache => dirname(__FILE__) . "/tmp/",
cache_lifetime => 600,
template_dir => dirname(__FILE__) . "/",
);
/**
* SmartTemplate Class
*
* 'Compiles' HTML-Templates to PHP Code
Hello_World.php<?php require_once "/home/ka1ijikijq/wwwroot/smarttemplate/class.smarttemplate.php";
// 同样需要绝对路径 $page = new SmartTemplate("Hello_World.html");
$page->assign('TITLE', 'Hello World!');
$page->output();?>