here is my code in my .htaccess
file:
RewriteCond %{HTTP_HOST} !^www\.domain\.com
RewriteCond %{HTTP_HOST} ([^.]+)\.domain\.com [NC]
RewriteRule ^/?$ /user/profile.php?name=%1 [L]
here is what it does:
if i visit test.domain.com
, it will show the contents (not redirect) of domain.com/profile.php?name=test
.
but if i type: test.domain.com/login
, it will show the contents of the page: domain.com/login
.
Question: why is that? how can i turn that off? thanks
Hope this will work, working fine on my end.
RewriteCond %{HTTP_HOST} !^www\.domain\.in
RewriteCond %{HTTP_HOST} ^test\.dmmain\.in [NC]
RewriteRule ^$ http://test.domain.in/user/profile.php [L,QSA]
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.