shervin6623 Posted March 1, 2014 Share Posted March 1, 2014 Dear developers I've got a seo problem here My website links set to be started with www. e.g www.mysite.com but whenever I got users from google with none www. links e.g http://mysite.com/21-fitness the link redirection became like this: http://mysite.com/21-fitness?controller=404 & google webmaster tools submite an error for my site, this affect my seo very badly as I stock at a low level rank does some body here know how to correct this mess ? I have to mention that I've already try this code in .htaccess but no result! RewriteEngine OnRewriteCond %{HTTP_HOST} ^bazeh.com$RewriteRule ^(.*)$ http://bazeh.com/$1 [L,R=301,QSA] sorry for my bad english Thanks in advance Shervin.Kh Link to comment Share on other sites More sharing options...
jordiob Posted March 2, 2014 Share Posted March 2, 2014 it looks like your theme could not be compilant with Cannonical URL Link to comment Share on other sites More sharing options...
El Patron Posted March 2, 2014 Share Posted March 2, 2014 Dear developers I've got a seo problem here My website links set to be started with www. e.g www.mysite.com but whenever I got users from google with none www. links e.g http://mysite.com/21-fitness the link redirection became like this: http://mysite.com/21-fitness?controller=404 & google webmaster tools submite an error for my site, this affect my seo very badly as I stock at a low level rank does some body here know how to correct this mess ? I have to mention that I've already try this code in .htaccess but no result! RewriteEngine On RewriteCond %{HTTP_HOST} ^bazeh.com$ RewriteRule ^(.*)$ http://bazeh.com/$1 [L,R=301,QSA] sorry for my bad english Thanks in advance Shervin.Kh I like this for non-www to www. I do not thing the one you posted is good for this. RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L] 1 Link to comment Share on other sites More sharing options...
shervin6623 Posted March 3, 2014 Author Share Posted March 3, 2014 I like this for non-www to www. I do not thing the one you posted is good for this. RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L] Thanks man This code do the job well 1 Link to comment Share on other sites More sharing options...
Recommended Posts