【问题标题】:Does specifying a directive create an exception after disallowing all bots at the beginning in robots.txt?在 robots.txt 的开头禁止所有机器人后,指定指令是否会创建异常?
【发布时间】:2019-04-22 05:54:00
【问题描述】:

案例如下:

User-agent: *
Disallow: /

User-agent: Googlebot
Disallow: /test

在这种情况下,Googlebot 是否能够完成其工作?

我猜可能是因为该文件仅指定禁止 Googlebot 的 /test,所以 Googlebot 可以在除 /test 之外的其他目录上执行其工作的变化?

【问题讨论】:

  • 您期望发生什么?据我所知,所有机器人都将被阻止访问所有 URL,Googlebot 将被双重阻止访问 /test URL。
  • 我不确定。我猜可能是因为该文件仅指定禁止 Googlebot 的 /test,所以 Googlebot 可以在除 /test 之外的其他目录上执行其工作的变化?
  • Googlebot 专门支持 Allow 指令,它可以满足您的需要

标签: search seo frontend backend search-engine


【解决方案1】:

问题:在这种情况下,Googlebot 是否能够完成其工作?

回答:不是这种情况

User-agent: *
Disallow: /

问题:我想可能是因为该文件仅指定禁止 Googlebot 的 /test,所以 Googlebot 可以在除 /test 之外的其他目录上执行其工作的变化?

回答:是的

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-10-15
    • 2021-06-20
    • 1970-01-01
    • 2020-10-06
    • 1970-01-01
    相关资源
    最近更新 更多