开发者

how can i stop google indexing pages with urls ending with date and time

I have a website with some pages like

and www.xyz.com/product1/date which can be dynamic as what user searches.

Current google is indexing

  • www.xyz.com/product1
  • www.xyz.com/product2
  • www.xyz.com/product1/date

I dont want google to index www.xyz.com/product1/date urls....


Maybe writing a proper robots meta tag:

  • HTML spec


You might be able to do what you want with a robots.txt at your website root directory

User-agent: *
Disallow: /product1/*


If the date was in the query part ie www.example.com/product1?date=yyyy-mm-dd you can tell Google to ignore the date argument via Google Webmaster Tools.

Could you make the trade off and move date to query part of URL?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜