Welcome to WebmasterWorld Guest from 54.197.75.176

Forum Moderators: goodroi

Message Too Old, No Replies

block ? with robots.txt or htaccess

     
1:00 pm on Jun 6, 2012 (gmt 0)

Senior Member

WebmasterWorld Senior Member zeus is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Apr 28, 2002
posts:3444
votes: 1


How can I block mysite. ​com​/?i​d=2​891​&ca​t=bla I get a lot of duplicated content of my frontpage, they all starts with ? after the domain

is this the right way in robots txt

User-agent: *
Disallow: /*?

I dont think so, be cause it blocks ? any where right, I just want if it comes after the domain
10:48 pm on June 8, 2012 (gmt 0)

New User

5+ Year Member

joined:Dec 3, 2009
posts:29
votes: 0


You really should be looking into the creation of query string URLs rather than blocking from search engines. Why is your website creating these pages in the first place?
Anyway if you do not want to answer for any reason, in your Goolge Webmaster Tools account you can tell Google Not to index these URL Parameters ?whatever
10:52 pm on June 8, 2012 (gmt 0)

Senior Member

WebmasterWorld Senior Member g1smd is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2002
posts:18903
votes: 0


Parameters right after the domain would be:

Disallow: /?



You should also add

Disallow: /index.php?


or similar.