php smarty tpl 错误信息 500,Chapter 20. 疑难解答

Warning: Smarty error: unable to read resource: "index.html" in...

or

Warning: Smarty error: unable to read resource: "site.conf" in...

$template_dir出现的错误, 在

templates/目录中

不存在index.tpl文件。

{config_load}函数,(或调用

configLoad()函数)

,$config_dir出现的错误,目录中找不到site.conf文件。

Fatal error: Smarty error: the $compile_dir 'templates_c' does not exist,

or is not a directory...

$compile_dir不正确,目录不存在;或者

templates_c不是目录而是文件。

Fatal error: Smarty error: unable to write to $compile_dir '....

$compile_dir在服务器上无法写入文件。

关于文件权限问题,参考下面

Smarty安装的文章。

Fatal error: Smarty error: the $cache_dir 'cache' does not exist,

or is not a directory. in /..

这意味着,$caching已经开启,

但$cache_dir

不正确,目录不存在;或者

cache/不是目录而是文件。

Fatal error: Smarty error: unable to write to $cache_dir '/...

这意味着,$caching

已经开启,

$cache_dir在服务器上无法写入文件。

关于文件权限问题,参考下面

Smarty安装的文章。

Warning: filemtime(): stat failed for /path/to/smarty/cache/3ab50a623e65185c49bf17c63c90cc56070ea85c.one.tpl.php

in /path/to/smarty/libs/sysplugins/smarty_resource.php

这意味着,你的应用程序已经注册了自定义错误处理器(使用

set_error_handler()),

但该处理器没有处理当前的$errno。

如果,不管什么理由,这是你的自定义错误处理器的处理方式的话,

那么在注册你的错误处理器后,调用

muteExpectedErrors()。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值