kangaby wrote:
Xan wrote:
he wanted people trying to go to "domain.com" to end up at "www.domain.com", not just seeing the same stuff, but with that address in the URL bar.
I guess I don't really understand the point. If
www.domain.com is the same content as domain.com, then why do a redirection at all.
If you really want them to only use
www.domain.com then set the server name to
www.domain.com and don't alias domain.com
Then only
www.domain.com will work.
Is there some special secret setup I'm missing here?
Users expect websites to be available at both example.com and
www.example.com. Making only one or the other work is just going to confuse and frustrate your visitors (or worse, make them think the site is down).
So, the only question is: do you serve the same content from both example.com and
www.example.com or do you redirect one to the other?
Redirecting one to the other is usually the better solution. Users will always be presented with your "preferred" url. Also, if people link to your site using both example.com and
www.example.com, using a 301 redirect tells google that all that pagerank flow should be consolidated into one page. If you're serving content from both, then google is going to have two pages in its index and they're both probably not going to perform very well in search results because the links are split between them.