Skip to content

Commit

Permalink
Add Alternate robots.txt section
Browse files Browse the repository at this point in the history
  • Loading branch information
JayHoltslander authored Nov 18, 2017
1 parent 01bccc6 commit 09fc854
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,19 @@



# REDIRECT ROBOTS.TXT REQUESTS TO STAGING SERVER'S VERSION IF NOT PRODUCTION SERVER'S DOMAIN
# Serve a different ("Do not index") version of robots.txt only when accessed on a subdomain of "stagingserver.com"
# Make sure file "robots-staging.txt" actually exists.
# Source: https://serverfault.com/a/884023/396075
#
#<IfModule mod_rewrite.c>
# RewriteEngine On
# RewriteBase /
# RewriteCond %{HTTP_HOST} ^(.*)?stagingserver(\.com)
# RewriteRule ^robots\.txt$ robots-staging.txt [NS]
#</IfModule>



# SHOW THE ADMIN’S EMAIL ADDRESS IN APACHE ERROR MESSAGES
#
Expand Down

0 comments on commit 09fc854

Please sign in to comment.