• I am using 3.0.1 with MU installed and I have a problem where I am trying to add city subdomains to my site and use .htaccess to do a redirect to a subfolder while keeping the original url. Ex:

    city.example.com -> example.com/city

    in .htaccess I am using the following code:

    RewriteCond %{HTTP_HOST} ([^.]+)\.example.com [NC]
    RewriteRule ^(.*) http://example.com/%1/$1 [P]

    With this, when I go to http://city.example.com/ it will go to the correct page and keep the url intact but if I go to any of the subpages of city such as http://city.example.com/foo it will force a redirect to http://example.com/city/foo/. If there is a php error or I go to a subpage that 404s, is will not force the redirect. This makes me think that WordPress is the one forcing the redirect. Does anyone know if this is correct and if so how can I work around this?

  • The topic ‘Subdomain Redirect Problems’ is closed to new replies.