httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marvin Vek <lc...@bit.nl.eu.org>
Subject [users@httpd] Rewrite rule, and then a special subdomain?
Date Fri, 11 Feb 2005 21:11:48 GMT
I configured my server to automaticly point username.domain.com to the 
users public_html directory.. (See here for more info)

Code:
	RewriteEngine On
	# Skip www.domain.com
	RewriteCond %{HTTP_HOST} !^(www\.)
	RewriteCond %{HTTP_HOST} ^([^.]+)\.domain\.com
	RewriteRule ^(.*)$  /home/%1/public_html$1


Now, that works perfect.. if for example user nike goes to 
http://nike.domain.com, he sees his own /home/nike/public_html dir. If 
user adidas goes to http://adidas.domain.com, he sees 
/home/adidas/public_html, and so on..

But now, i need a subdomain.domain.com to point to a certain directory.. 
how do i do that?

For example, i want to have stats.domain.com to point to directory 
/home/admin/public_html/stats, and not /home/stats/public_html..

How do i do that, and keep the username.domain.com rewrite rule working?


-- 
Marvin Vek


---------------------------------------------------------------------
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


Mime
View raw message