windows下model名和表名不一样import无法导入model

浏览:553 发布日期:2014/09/04 分类:求助交流 关键字: windows model 模型 bug 无法加载
大家好,我在linux环境下开发系统。
同事在用windows时候使用我的代码。//CommonModel 自动继承
function CM($name){
    static $_model = array();
    if(isset($_model[$name])){
        return $_model[$name];
    }
    $class=$name."Model";
    import('@.Model.' . $class);
    if(class_exists($class)){
        $return=new $class();
    }else{
        $return=M("CommonModel:".$name);
    }
    $_model[$name]=$return;

return $return;
}
跟踪调试发现function file_exists_case($filename) {
    if (is_file($filename)) {
        if (IS_WIN && APP_DEBUG) {
            if (basename(realpath($filename)) != basename($filename))
                return false;
        }
        return true;
    }
    return false;
}
中is_file函数判断失效,请问大家在windows下是否有同样遭遇?如何解决?
最佳答案
评论( 相关
后面还有条评论,点击查看>>