Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Googlebot 不断尝试在我的网站上调用 ajax 方法。例如:default.aspx/GetStuffWithAjax
问题是谷歌应该不可能调用这个方法,因为我在调用它之前使用 javascript 检查查询字符串是否有 id=xxxx。谷歌可以遵循此查询字符串的任何地方都没有链接。
机器人是否有可能在我的 html 代码中扫描 PageMethods.GetStuffWithAjax,然后尝试调用 ajax 方法?我怎么能防止这种情况..有人吗?
在您的域根目录下的文件中放置Disallow: /GetStuffWithAjax一行。robots.txt
Disallow: /GetStuffWithAjax
robots.txt
你可以robots.txt用来告诉谷歌(和其他优秀的机器人)不要去那里。在这里检查: