code_junkie

How can I redirect requests to specific files above the site root?

Nov 13th, 2011
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. robots.txt+favicon.ico go into => /fileserver/files/mywebsite_com/stuff
  2.  
  3. RewriteRule ^(robots.txt|favicon.ico)$ ../stuff/$1 [L]
  4.  
  5. Alias /robots.txt /fileserver/files/mywebsite_com/stuff/robots.txt
  6.  
  7. <Directory /fileserver/files/mywebsite_com/stuff>
  8. Order allow,deny
  9. Allow from all
  10. </Directory>
  11.  
  12. ln -s /fileserver/files/mywebsite_com/stuff/robots.txt /fileserver/files/mywebsite_com/stuff/favicon.ico /fileserver/mywebsite_com/www/
Add Comment
Please, Sign In to add comment