虚拟主机www.xxx.cn下:---+smarty----+Smarty.class.php
|
+www-----------+smarty.inc.php
|
+index.php [require("smarty.inc.php")]
------------------------------------------------------------------
则:smarty.inc.php中是这样写的: define("SMARTY_DIR","./smarty/");
define("WWW",SMARTY_DIR."/www/");
require_once(SMARTY_DIR."Smarty.class.php");
但是 报错了:Warning: require_once(..Smarty.class.php) [function.require-once]: failed to open stream: No such file or directory in /home/acruxcn/public_html/zxs/smarty/www/smarty.inc.php on line 4
路径出错,应该怎么改正呢?
|
+www-----------+smarty.inc.php
|
+index.php [require("smarty.inc.php")]
------------------------------------------------------------------
则:smarty.inc.php中是这样写的: define("SMARTY_DIR","./smarty/");
define("WWW",SMARTY_DIR."/www/");
require_once(SMARTY_DIR."Smarty.class.php");
但是 报错了:Warning: require_once(..Smarty.class.php) [function.require-once]: failed to open stream: No such file or directory in /home/acruxcn/public_html/zxs/smarty/www/smarty.inc.php on line 4
路径出错,应该怎么改正呢?
www文件夹在smarty文件夹下面的
www.xxx.cn/smarty/www
写得很清楚,明显少了/
还有建议LZ用绝对路径