-
MODX Staff
- 12,272 Posts
Where does Google state they prefer "www" URLs? That’s certainly news to me!
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
It’s something the guys over at SitePoint told me.
-Dorian
-
☆ A M B ☆
- 24,524 Posts
Even slashdot just uses slashdot.org
-
☆ A M B ☆
- 1,056 Posts
I think the key here is consistency. "www" or not, you should ensure your URL’s "preferred domain" (as Google calls it) is always equal. This can eliminate "duplicate content" which can land your pages in Google’s Supplemental Index, etc.
Consider the following:
http://mydomain.com
http://www.mydomain.com
http://www.myddomain.com/index.php?id=1
http://myddomain.com/?q=index
http://www.myddomain.com/index.php
http://myddomain.com/?id=1
http://myddomain.com/index.html (With friendly URLs enabled)
Each of the pages listed above are the
exact same page (identical content), while the URL itself appears to be unique. Google (and other search engines) may not realize that it is actually looking at the same document (as far as the URL is concerned) and therefore may flag them as duplicates of each other...even though it’s the same page!
Using .htaccess is the ideal way to enforce "preferred domain" which will take care of these instances:
http://mydomain.com
http://www.mydomain.com
The URL above would be rewritten to enforce your preferred domain (e.g. No "www":
http://www.mydomain.com becomes
http://mydomain.com)
SEO Strict URLs is a great plugin that will take care of properly
301 Redirecting all remaining URL possibilities to the correct match:
http://myddomain.com/index.php?id=1
http://myddomain.com/?q=index
http://myddomain.com/index.php
http://myddomain.com/?id=1
http://myddomain.com/index.html (With friendly URLs enabled)
all would be 301 redirected to:
http://mydomain.com
Whatever you choose to implement as your preferred domain, remaining consistent is my advice.
Great summary, and something I should keep in mind and be more consistent about, I confess
.: COO - Commerce Guys - Community Driven Innovation :.
MODx est l'outil id