V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
c0427
V2EX  ›  问与答

robots.txt 书写疑问

  •  
  •   c0427 · 2016-01-31 10:35:40 +08:00 · 1103 次点击
    这是一个创建于 3030 天前的主题,其中的信息可能已经有所发展或是发生改变。
    目前内容页面的首页为 www.xxx.com/t*.html ,翻页后为 www.xxx.com/t*-#.html (* 为 ID ,# 为页码)。我想要搜索引擎只收录内容页面的首页,而不收录第二页和第三页,那么我在 robots.txt 里写下了如下的规则,请问正确吗?否则应该如何书写?谢谢。

    Disallow: /t-*.html
    Allow: /t*.html
    1 条回复    2016-01-31 10:57:41 +08:00
    c0427
        1
    c0427  
    OP
       2016-01-31 10:57:41 +08:00
    已使用谷歌 robots.txt 测试工具解决。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   1569 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 00:34 · PVG 08:34 · LAX 17:34 · JFK 20:34
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.