None of them are better then the other. But you will only have one at a time. If you got 2 then you most change it in your .htaccess file or else search engines will rank both of them as 1 site each.
How to change it? If I type www, my Drupal site won't show up. Without www, the Drupal site shows up. What to do now?
Neither is better, but it's best to stick with one working format. Enter the below code into your .htaccess file. This will properly foward ALL urls that point to non-www to www. RewriteEngine on RewriteCond %{HTTP_HOST} ^yourdomain\.com$ [NC] RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L] Replace yourdomain.com with your domain name, make sure to leave the ENTIRE code intact when replacing, this includes leaving the "\".
Could you help me with this ? last time i tried i screwed up my site, thank god i had backup. pm me if you can.
Hey nice tips! If I have this in my .htaccess file: Should I leave it there or I can remove it because it doesn't matter? If I want it to redirect from www to non-www I guess this is the code: Right? Also, if I already have links that point to www.yourdomain.com redirecting my website to non-www will affect SERPS? Cheers, Vlad