robots.txt and 302 redirects
I have page1.html that is being 302 redirected (temporary redirect) to page2.html
page2.html is disallowed in my robots.txt file
Under normal circumstances, when googlebot encounters a 301 redirect from page1.html to page2.html, it will index page2.html, and when googlebot encounters a 302 redirect from page1.html to page2.html, it will index page1.html
Since, theoretically, the url of page1.html is what would be indexed, would it still be indexed considering page2.html is blocked?
cscgal
The Queen of DaniWeb
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229
I would think that because you redirect page1 to page2 the search engine will include it in a crawl despite a robot.txt instruction to do otherwise.
canadafred
SEO Consultant
1,021 posts since Feb 2006
Reputation Points: 192
Solved Threads: 28
Would it just crawl (b/c when it first finds page1.html, it is a valid url for it), or would it actually index the contents of page2.html, despite a robots.txt file to disallow crawling or indexing of page2.html?
cscgal
The Queen of DaniWeb
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229
It's been a couple of days, and Google Webmaster Tools is now showing me that page1.html is not being crawled due to being blocked in my robots.txt file, even though it is only page2.html that is actually listed in robots.txt.
This is the desired effect, in my case.
cscgal
The Queen of DaniWeb
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229