Error:check Snooping out of bounds 的解決辦法
Error:check Snooping out of bounds 的解決辦法
在本機 E:\wwwroot\DedeCMS\v57\ 下安裝了V57最新版本的主程序,安裝成功後,生成首頁提示 :
Error:check Snooping out of bounds @ D:\wwwroot\gdhgc\wwwroot\kj\templets\default\index.htm
使用notepad++搜索了下包含 Error:check Snooping out 的文件,找到 include/dedetag.class.php 文件的第
325行,內容如下
if (strpos($path, $this->clean(DEDEROOT)) !== 0) {
die('Error:check Snooping out of bounds @ '.$path);
}
windows下是不區分路徑大小寫的,在使用strpos時我們需要忽略大小寫,修改上述內容爲如下:
if (stripos($path, $this->clean(DEDEROOT)) !== 0) {
die('Error:check Snooping out of bounds @ '.$path);
}
出現該問題,主要是路徑中包含了大寫字母,使用stripos操作時忽略大小寫。
文章來源 http://zencart.me/archives/54