用wdcp设置了301,按照wdcp官方的教程。用工具查询,返回是301没错
第二天查看日志,蜘蛛返回的代码,都是302.。。。比如这一条:
220.181.108.121 - - [11/Aug/2014:23:34:42 +0800] "GET /thread-518-1-1.html HTTP/1.1" 302 20 "-" "Mozilla/5.0 (compatible; Baiduspider/2.0; +http冒号//www点baidu点com/search/spider.html)[/code]
你们去看下自己的日志,有这个情况吗?
我能想到的出问题的地方,就是wdcp设置301的时候要分别建立带www和不带www 的两个网站
你们那个不带www的绑定的目录,和带www的绑定的目录是同一个吗?
$ curl -IL http://ogtui.com/thread-518-1-1.html
HTTP/1.1 301 Moved Permanently
Date: Tue, 12 Aug 2014 13:56:07 GMT
Server: Apache
Location: http://www.ogtui.com/thread-518-1-1.html
Vary: Accept-Encoding
Connection: close
Content-Type: text/html; charset=iso-8859-1
HTTP/1.1 302 Found
Date: Tue, 12 Aug 2014 13:56:07 GMT
Server: Apache
X-Powered-By: PHP/5.3.17
Set-Cookie: RSem_4fb2_saltkey=aAe90LZE; expires=Thu, 11-Sep-2014 13:56:07 GMT; path=/; domain=.ogtui.com; httponly
Set-Cookie: RSem_4fb2_lastvisit=1407848167; expires=Thu, 11-Sep-2014 13:56:07 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_sid=vhh5Jj; expires=Wed, 13-Aug-2014 13:56:07 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_lastact=1407851767%09forum.php%09viewthread; expires=Wed, 13-Aug-2014 13:56:07 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_visitedfid=44; expires=Thu, 11-Sep-2014 13:56:07 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_viewid=tid_518; path=/; domain=.ogtui.com
Location: forum.php?mod=viewthread&tid=518
Vary: Accept-Encoding
Connection: close
Content-Type: text/html; charset=gbk
HTTP/1.1 200 OK
Date: Tue, 12 Aug 2014 13:56:08 GMT
Server: Apache
X-Powered-By: PHP/5.3.17
Set-Cookie: RSem_4fb2_saltkey=VngZI0p4; expires=Thu, 11-Sep-2014 13:56:08 GMT; path=/; domain=.ogtui.com; httponly
Set-Cookie: RSem_4fb2_lastvisit=1407848168; expires=Thu, 11-Sep-2014 13:56:08 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_sid=tsnWTz; expires=Wed, 13-Aug-2014 13:56:08 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_lastact=1407851768%09forum.php%09viewthread; expires=Wed, 13-Aug-2014 13:56:08 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_visitedfid=44; expires=Thu, 11-Sep-2014 13:56:08 GMT; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_viewid=tid_518; path=/; domain=.ogtui.com
Set-Cookie: RSem_4fb2_sid=tsnWTz; expires=Wed, 13-Aug-2014 13:56:08 GMT; path=/; domain=.ogtui.com
Vary: Accept-Encoding
Connection: close
Content-Type: text/html; charset=gbk
-------------------------
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。