The MU forums have moved to WordPress.org

Main Site with www (3 posts)

  1. McDot
    Member
    Posted 13 years ago #

    Hi, I would want to set the main site on http://www.mydomain.tld, the version without www should redirect to www.
    All user subdomains should remain without www

    Anyone know how I can do this?

  2. VentureMaker
    Member
    Posted 13 years ago #

    To the best of my knowledge, it can be either WITH www or WITHOUT it.
    If your domain is with www - then subdomains too are with www.

  3. Pegasus-18
    Member
    Posted 13 years ago #

    I'm not really sure if its possible either, but maybe via htaccess:

    RewriteEngine On
    RewriteCond %{HTTP_HOST} !^www\.domain\.com$ [NC] [OR]
    RewriteCond %{HTTP_HOST} !^subdomain\.domain\.com$ [NC]
    RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]

    This prohibits rewriting for "www" and "subdomain". Not sure if thats what you want. Else have a look at modrewrite.de or .com to ask the htaccess experts out there. :-)

About this Topic

  • Started 13 years ago by McDot
  • Latest reply from Pegasus-18