domain => subdomain.domain.com
target => subdomain.domain.com/Controller/Method
我会
IF %{HTTP_HOST} == base_url(subdomain.domain.com)
重定向到目标(subdomain.domain.com/Controller/Method)
我没有修复基本域名
答案 0 :(得分:0)
尝试:
# Considering that base domain URL excludes index.html, index.php, welcome.html or something like that, we'll reduce matches to http(s)://base.subdomain/ and http(s)://base.subdomain
RewriteCond %{REQUEST_URI} ^\/?$
RewriteRule /Controller/Method
答案 1 :(得分:0)
您可以使用以下规则:
|