• This is my third try at getting some help for this. (previous post here – http://wordpress.org/support/topic/adding-multisite-removed-www-from-my-url-causing-broken-links?replies=2 )

    When I was intalling multisite I was instructed to remove the www from my site URLs, i did.

    But now I realise this has caused a lot of internal and external broken links. Last time I posted on the forum was told to add a 301 redirect to my .htaccess file, which i did but this just means all the links now lead to the homepage not to where there were supposed to.

    this is the code i added:
    # Getting rid of the WWW in front
    RewriteCond %{HTTP_HOST} ^www.dropdeadgorgeousdaily.com [NC]
    RewriteRule ^(.*)$ http://dropdeadgorgeousdaily.com/$1 [L,R=301]

    I need to either find a way to make these redirect to the non www version of the pages they originally pointed to, or get the www back in the URL.

    I know usually you would just add it back in the admin panel but this is greyed out (my multisite set up is subdomains not subdirectories, happy to even change that back if i can).

    Help please this is very important.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    That code, if put above the WordPress section does exactly that. It changes http://www.domain.com/(anything) to domain.com/(anything).

    All links DO NOT lead to the home page (or rather, should not) unless you’re not using a *nix/Apache combo. I have no idea what it does on IIS.

    Where in your .htaccess did you put this?

    Another thing you can do is make WP handle the redirecting, if you’ve installed the “WordPress MU Domain Mapping” plugin and added a wildcard (*.yourdomain.com) in apache…
    – Go to Super Admin > Options and remove ‘www’ from the banned names.
    – Go to Super Admin > Domains and fill in the main blog-id in Site ID and ‘www.yourdomain.com’ in Domain. Save and it should work.

    Thread Starter kateM82

    (@ddgdaily)

    Thanks ipstenu, I didn’t realise it mattered where I put it so I put it at the end. All working now. Phew!

    Thread Starter kateM82

    (@ddgdaily)

    And thanks David, I might have a play around with both and see which works best. Both champions! 🙂

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘When installing multisite you have to 'remove www' from site URL, can't undo!’ is closed to new replies.