Skip to main content Help Control Panel

Share
Post to Facebook
Tweet about this
Share at LinkedIn
Invite participants
Reference this page
Monitor
Recent files
English »
See also
  • Oct. 2007 (80 pages)
  • Search Engine Optimisation (SEO) (27 pages, 1 user) Le référencement est une étape importante dans la conception d'un site Internet.
    Dans une liste des priorités, il est à mettre au même niveau que la création d'une charte graphique, d'une organisation du contenu rédactionnel et de l'information.
    Cela tombe plutôt bien car Yacs vous facilite la gestion de toutes ces priorités, référencement compris.
  • Url (4 pages)
  • Week of 10/15/07 (25 pages)
  • Www (1 page)
 

English «   Post your requirements here «  

SEO www redirects in htaccess (code included)

How about this to help improve SEO. Will require hand editting to enable correct rule and domain name. I have this running my my site without problem.

Needs to be the first rewrite rule in the list.

# redirect all to http://www.example.com/...
#
RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]
#
# redirect http://www.example.com/... to http://example.com/...
#
# RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC]
# RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]


:)

Bernard Paquesfrom nearby-an-airport
Associate, 8408 posts

on Oct. 20 2007


Nick, i don't understand how this help SEO. Can you explain please?
NickR

on Oct. 20 2007


Because they are different urls and google considers it duplicate cotent, which google gives a penatly to. Usually not an issue, but this prevents it happening at all.
-----
Nick