网站站长工具中/a文件夹的404错误 [英] 404 errors on /a folders in Webmaster Tools

查看:138
本文介绍了网站站长工具中/a文件夹的404错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Google网站管理员工具中,在抓取错误下,我遇到的第404错误是所谓的

In Google Webmaster Tools, under crawling errors, my number one 404 error is something called

www.domain.com/a 

我的网站上没有这样的东西,也没有链接.怎么了,这是什么意思?在站点日志中,没有关于指向/a的404错误的错误. W3C检查器说没有错误.我该怎么办?

There is no such thing in my site and there is no link to it. What is wrong, what does it mean? In the site log, there is no error about 404 error pointing to /a. W3C checker says no error. What can I do?

推荐答案

不是您,它必须是Googlebot. (这与php无关; 也许有人可以删除php标签.)

It's not you, it has to be the Googlebot. (none of this has to do with php; perhaps somebody can remove the php tag.)

我的Google网站站长工具中有八个网站,两个完全不相关的网站也显示相同的内容.均未显示此问题的网站都使用PHP.

I have eight sites in my Google Webmaster Tools and two totally unrelated sites are showing this same thing. Neither site showing this issue uses PHP.

我唯一能想到的是Google的漫游器错误地解析了HTML,并以某种方式在根URL上附加了结束符"a".听起来很愚蠢,但这是唯一可以解释此问题的多个不相关实例的东西.

有人在Google论坛中对此发起了话题吗?

我不确定这将对根本问题产生什么影响,但是我将其放在htaccess文件中,希望可以清除错误的404错误. ( ,这是Google推荐的解决方案.)

I'm not sure what effect this will have on the root problem but I put this in my htaccess file to hopefully clear out the false 404 errors. ( this is the recommended solution by Google.)

Redirect 301   /a   http://www.mysite.com


已报告给Google帮助论坛:

Reported to Google Help Forum:

http://www.google. com/support/forum

两个站点均在W3C上进行了验证,并且均未使用PHP.

Both sites validate at the W3C and neither use PHP.

"/a"来自jQuery v1.5.2内部.这是根本原因.

The "/a" is coming from inside jQuery v1.5.2. This is the root cause.

在jQuery本身中是这一行...

Within jQuery itself is this line...

<a href='/a' style='color:red;float:left;opacity:.55;'>a</a>


使用robots.txt文件对其进行阻止. (根据Google的说法,这只会将网站站长工具抓取错误从"404"更改为被robots.txt阻止" )

Block it with the robots.txt file. (According to Google, this will only change the Webmaster Tools Crawl Error from a "404" to a "Blocked by robots.txt")

Disallow:  /a/
Disallow:  /a


修改5:

以下是Google员工JohnMu在我在Google网上论坛中发起的话题.看来我还是要坚持使用301.

The following is a response from Google employee JohnMu on this issue in the thread I started at Google Groups. Looks like I'm going to stick with the 301 after all.

JohnMu

JohnMu

Google员工

4:39 AM

大家好

这只是一个简短的说明-是的,我们 正在为许多人选择"/a"链接 jQuery JavaScript网站.然而, 如果我们 看到"/a"为404,那么 对我们很好.与其他404-URL一样, 我们将其列为抓取错误 网站管理员工具,但这又不是 爬行会成为一个问题, 索引或排名.如果你想 确保它不会触发 在网站站长工具中抓取错误,然后我 将建议仅301重定向 该网址到您的首页(不允许 该网址还会将其显示为 抓取错误-将列为 robots.txt禁止使用的网址).

Just a short note on this -- yes, we are picking up the "/a" link for many sites from jQuery JavaScript. However, that generally isn't a problem, if we see "/a" as being a 404, then that's fine for us. As with other 404-URLs, we'll list it as a crawl error in Webmaster Tools, but again, that's not going to be a problem for crawling, indexing, or ranking. If you want to make sure that it doesn't trigger a crawl error in Webmaster Tools, then I would recommend just 301 redirecting that URL to your homepage (disallowing the URL will also bring it up as a crawl error - it will be listed as a URL disallowed by robots.txt).

我也建议不要明确 禁止抓取jQuery 文件.虽然我们通常不会 自行为其编制索引,我们可能需要 访问它以生成良好的即时 您网站的预览.

I would also recommend not explicitly disallowing crawling of the jQuery file. While we generally wouldn't index it on its own, we may need to access it to generate good Instant Previews for your site.

所以总结一下:如果您看到"/a" 网站管理员中的抓取错误中 工具,就可以像 那不会造成任何问题.如果 你想把它移到那里,你 可以将301重定向到您的 主页.

So to sum it up: If you're seeing "/a" in the crawl errors in Webmaster Tools, you can just leave it like that, it won't cause any problems. If you want to have it removed there, you can do a 301 redirect to your homepage.

欢呼

约翰

这篇关于网站站长工具中/a文件夹的404错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆