Force www on WordPress 3.0 Multisite

If you have installed wordpress 3.0 Multisite on a domain with “www” with the subdomain option and you visit your the domain without the “www”, it default redirects to http://www.yoursite.nl/wp-signup.php?new=yoursite.nl

Now, if you want to to force the the “www” wich means redirecting http://yoursite.nl to http://www.yoursite.nl add the snippet of code below to your .htaccess file.

This code is a little bit different then the usual code found on other sites.

Force www for WordPress Multisite 3.0

RewriteEngine On
RewriteCond %{HTTP_HOST} ^yoursite.nl$ [NC]
RewriteRule ^(.*)$ http://www.yoursite.nl/  [L,R=301]

Standard force www

RewriteEngine On
RewriteCond %{HTTP_HOST} ^www.yoursite.nl$ [NC]
RewriteRule ^(.*)$ http://www.yoursite.nl/  [L,R=301]