PHP和Smarty:FilemTime():Stat失败 [英] PHP and Smarty: filemtime(): stat failed

查看:34
本文介绍了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失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆