ASP.NET MVC GoogleBot 问题
我使用 ASP.NET MVC 编写了一个网站,虽然此时它还没有完全优化 SEO,但我认为这是一个好的开始。我发现,当我使用 Google 的网站管理员工具获取我的网站(以查看 GoogleBot 看到的内容)时,它会看到此内容。
HTTP/1.1 200 OK
Cache-Control: public, max-age=1148
Content-Type: application/xhtml+xml; charset=utf-8
Expires: Mon, 18 Jan 2010 18:47:35 GMT
Last-Modified: Mon, 18 Jan 2010 17:07:35 GMT
Vary: *
Server: Microsoft-IIS/7.0
X-AspNetMvc-Version: 2.0
X-AspNet-Version: 2.0.50727
X-Powered-By: ASP.NET
Date: Mon, 18 Jan 2010 18:28:26 GMT
Content-Length: 254
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>
Index
</title>
</head>
<body>
</body>
</html>
显然,这不是我的网站的样子。我不知道 Google 从哪里获取该 HTML。有人有答案和解决方案吗?有人遇到同样的问题吗?
提前致谢。
I wrote a site using ASP.NET MVC, and although it is not completely SEO optimized at this point I figured it is a good start. What I'm finding is that when I use Google's Webmaster Tools to fetch my site (to see what a GoogleBot sees) it sees this.
HTTP/1.1 200 OK
Cache-Control: public, max-age=1148
Content-Type: application/xhtml+xml; charset=utf-8
Expires: Mon, 18 Jan 2010 18:47:35 GMT
Last-Modified: Mon, 18 Jan 2010 17:07:35 GMT
Vary: *
Server: Microsoft-IIS/7.0
X-AspNetMvc-Version: 2.0
X-AspNet-Version: 2.0.50727
X-Powered-By: ASP.NET
Date: Mon, 18 Jan 2010 18:28:26 GMT
Content-Length: 254
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>
Index
</title>
</head>
<body>
</body>
</html>
Obviously this is not what my site looks like. I have no clue where Google is getting that HTML from. Anybody have an answer and a solution? Anybody experience the same issues?
Thanks in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您可以使用 Firefox 的用户代理切换器插件来发出请求,就像 GoogleBot 那样。 https://addons.mozilla.org/en-US/firefox/addon/ 59
我试过了,你的网站看起来不错。我会联系谷歌看看这是否是他们的问题。
You can use the User Agent Switcher plugin for Firefox to make a request much like GoogleBot would. https://addons.mozilla.org/en-US/firefox/addon/59
I tried it and your site looks fine. I would contact Google to see if it's a problem on their end.
您的根文件夹中是否有这些文件?
看起来它可能会抓住其中之一。如果这没有帮助,您可能需要发布主页的 html。
Do you have any of these files in the root folder?
It looks like it may be grabbing one of those instead. If that doesn't help you may need to post the html of your home page.
您的内容类型似乎不对。
我的方法是:
如果这不起作用(我认为应该如此),请尝试关闭缓存。
Your content-type seems off.
Mine is:
If that doesn't work (which I think it should), try turning off caching.