From b49a2ed6571fa7e85dc550aba0770bae5292088b Mon Sep 17 00:00:00 2001 From: thinkphp Date: Tue, 12 Jan 2016 19:03:43 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E8=AF=95=E6=A8=A1=E5=BC=8F=20window?= =?UTF-8?q?=E4=B8=8B=E9=9D=A2=E8=87=AA=E5=8A=A8=E5=8A=A0=E8=BD=BD=E4=B8=A5?= =?UTF-8?q?=E6=A0=BC=E6=A3=80=E6=B5=8B=E5=A4=A7=E5=B0=8F=E5=86=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Loader.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/library/think/Loader.php b/library/think/Loader.php index 3059f178..38c69358 100644 --- a/library/think/Loader.php +++ b/library/think/Loader.php @@ -54,8 +54,12 @@ class Loader } $filename = $path . str_replace('\\', DS, $class) . EXT; if (is_file($filename)) { + // 开启调试模式Win环境严格区分大小写 + if (APP_DEBUG && IS_WIN && false === strpos(str_replace('/', '\\', realpath($filename)), $class . EXT)) { + return; + } include $filename; - } elseif (APP_DEBUG) { + } else { Log::record(' autoloader error : ' . $filename, 'notic'); } }