user1449369
user1449369

Reputation: 67

htaccess - forcing non-www to www across entire site

With:

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

its redirecting http://mysite.org to http://www.mysite.org just fine

........ however if anything is trailing, its not forcing the www.

IE

http://mysite.org/b/ is NOT redirecting to http://www.mysite.org/b/

Upvotes: 0

Views: 24

Answers (1)

Prix
Prix

Reputation: 19528

Make sure there is only one .htaccess and that the folder b doesn't have a inner .htaccess or any other folder that is not redirecting. Besides that your rule should work just fine.

Upvotes: 1

Related Questions