Reputation: 65
I'd like to disallow all subdirectories in my folder /search
but allow indexing the search folder itself (I have content on /search
).
Testing this does not work:
User-Agent: *
Allow: /search/
Disallow: /search/*
Upvotes: 5
Views: 1437
Reputation: 371163
Your code appears correct. Try with a slight adjustment to Allow
:
User-Agent: *
Disallow: /search/*
Allow: /search/$
Upvotes: 5