今天我的一个站www.xxfs.com 在http://www.webkaka.com/ 测试网速,发现域名状态为302跳转,经咨询kaka站长,说是http访问www.xxfs.com后先302跳转到www.xxfs.com/mobile目录,再跳转到www.xxfs.com,经google搜索,找到解决方法,在根目录找到index.php,第28行,找到代码
if(($ua == '' || preg_match($uachar, $ua))&& !strpos(strtolower($_SERVER['REQUEST_URI']),'wap'))
去掉
$ua == ’’ ||
就OK了,更改后的文件为
if((preg_match($uachar, $ua))&& !strpos(strtolower($_SERVER['REQUEST_URI']),'wap'))
找了一下,许多用ecshop建的站都有这个毛病。
ecshop域名被302重定向到mobile目录解决方法
- 还没有评论.