PHP and Smarty: filemtime(): stat failed(PHP和Smarty:FilemTime():Stat失败)
本文介绍了PHP和Smarty:FilemTime():Stat失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我收到以下错误filemtime(): stat failed。
完整错误为:
ERRNO:2 Text:FilemTime():统计失败 C:hatshop/presentation//templates_c74b952bedd7366ad261e8be04bc5be8ef15c2fc1.file.departments_list.tpl.php 地点:C:hatshoplibssmartysyspluginssmarty_resource.php,线 720,2013年3月30日12:14,显示回溯: Filemtime("C:hatshop/presentation//templates_c74b952bedd7366ad261e8be04bc...") #第720行,文件:C:hatshoplibssmartysyspluginssmarty_resource.php SMARTY_TEMPLATE_Source.getCompiled(对象:SMARTY_INTERNAL_TEMPLATE)# 第654行,文件: C:hatshoplibssmartysyspluginssmarty_internal_template.php SMARTY_INTERNAL_TEMPLATE.__GET("已编译")#第154行,文件: C:hatshoplibssmartysyspluginssmarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch(NULL,FALSE, FALSE,TRUE)#第286行,文件: C:hatshoplibssmartysyspluginssmarty_internal_template.php Smarty_Internal_Template.getSubTemplate("departments_list.tpl",为空, 空,数组[0],"0")#第34行,文件: C:HATSHOW Presentation emplates_c3522bf5c12e26ac546fbfc3693da6da22f71f1d6.file.index.tpl.php Content_5155dc5df33599_26514511(对象:SMARTY_INTERNAL_TEMPLATE)# 第180行,文件: C:hatshoplibssmartysyspluginssmarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch("index.tpl",NULL、NULL、NULL True)#第374行,文件: C:hatshoplibssmartysyspluginssmarty_internal_templatebase.php Smarty_Internal_TemplateBase.display("index.tpl")#第7行,文件: C:hatshop index.php我读过很多关于这个问题的帖子,但大多数 他们不清楚如何应用解决方案,他们只是在 一种非常不清楚的方式。
推荐答案
我有相同的错误,通过添加:
解决了它$this->error_reporting = E_ALL & ~E_NOTICE;
$this->muteExpectedErrors();
转到我的应用程序.php
<?php
// Reference Smarty library
require_once SMARTY_DIR . 'Smarty.class.php';
/* Class that extends Smarty, used to process and display Smarty
files */
class Application extends Smarty {
// Class constructor
public function __construct() {
// Call Smarty's constructor
parent::__construct();
$this->error_reporting = E_ALL & ~E_NOTICE;
$this->muteExpectedErrors();
// Change the default template directories
$this->template_dir = TEMPLATE_DIR;
$this->compile_dir = COMPILE_DIR;
$this->config_dir = CONFIG_DIR;
$this->addPluginsDir(SMARTY_DIR . 'plugins');
$this->addPluginsDir(PRESENTATION_DIR . 'smarty_plugins');
}
}
?>
务必检查此链接:
http://www.smarty.net/forums/viewtopic.php?t=21352&sid=88c6bbab5fb1fd84d3e4f18857d3d10e
这篇关于PHP和Smarty:FilemTime():Stat失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
织梦狗教程
本文标题为:PHP和Smarty:FilemTime():Stat失败
基础教程推荐
猜你喜欢
- 有什么方法可以用编码 UTF-8 而不是 Unicode 返回 PHP`json_encode`? 2021-01-01
- YouTube API v3 点赞视频,但计数器不增加 2022-01-01
- 如何替换eregi() 2022-01-01
- Cron Jobs 调用带有变量的 PHP 脚本 2022-01-01
- 学说 dbal querybuilder 作为准备好的语句 2022-01-01
- PHP PDO MySQL 查询 LIKE ->多个关键词 2021-01-01
- 在PHP中根据W3C规范Unicode 2022-01-01
- 如何在 Laravel 中使用 React Router? 2022-01-01
- PHP 类:全局变量作为类中的属性 2021-01-01
- 如何在 Laravel 5.3 注册中添加动态下拉列表列? 2021-01-01
