You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Patrick Donker <pa...@reporters.net> on 2003/06/26 01:44:31 UTC
[users@httpd] Mod_Rewrite question
Hi guys,
1st of all, I'm a total newbe to both this mailinglist and mod_rewrite,
so pardon me if I'm asking this question while it has been asked a
zillion times before, or if it is the wrong place to ask it.
My problem is the following:
I'd like to define a DocumentRoot based on the referer. So, if referer
would be http://www.somesite.com/, docroot should be
/server/www.somesite.com. If ref is http://192.168.0.100, then
/server/192.168.0.100.
My (non-functional) rule is:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://www.somesite.com/$ [NC]
RewriteCond %(DOCUMENT_ROOT) !^/var/www/html$
RewriteRule ^/$1 /server/www.somesite.com [R,L]
Obviousely, this doesnt work...how DO I make it work???
Thanks for any hints
Patrick
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org