homepage Welcome to WebmasterWorld Guest from 54.161.166.171
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Pubcon Platinum Sponsor 2014
Home / Forums Index / Search Engines / Sitemaps, Meta Data, and robots.txt
Forum Library, Charter, Moderators: goodroi

Sitemaps, Meta Data, and robots.txt Forum

    
How Do I Code My Robots.txt File To Disallow Subdomians?
Is it Disallow: /apple.domain.com or Disallow: /apple/
Christyl Stevens




msg:1526583
 9:11 am on Feb 2, 2004 (gmt 0)

If I have the following subdomains on my site then what would my robots.txt file look like and where would I put it to exclude ALL of my subdomains from being indexed?

[apple.domain.com...]

[banana.domain.com...]

[orange.domain.com...]

1.) Would I place the following code

User-agent: *
Disallow: /

In the root directory of my subdomains?

Just like the following since they are treated as separate domains?

[apple.domain.com...]

[banana.domain.com...]

[orange.domain.com...]

2.) Or would I simply place this code in my root directory of my domain, like this?

[domain.com...]

User-agent: *
Disallow: /apple.domain.com
Disallow: /banana.domain.com
Disallow: /orange.domain.com

3.) Or would I simply place this code in my root directory of my domain, like this?

[domain.com...]

User-agent: *
Disallow: /apple/
Disallow: /banana/
Disallow: /orange/

TIA

 

mbauser2




msg:1526584
 9:34 am on Feb 2, 2004 (gmt 0)

#1

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Search Engines / Sitemaps, Meta Data, and robots.txt
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved