0

Quick domain question: A clients site: www.workingwardrobes.org, does not work if I take off the www. .Someone told me that I have to do a DNS change and add the non www. with the same ip as the www. However, can't I just fix this with some sort of htacess?

Chris
  • 1,881
  • 3
  • 20
  • 27

3 Answers3

2

Unlikely. If the non-www URL isn't hitting the server, it won't hit your .htaccess and that's what it sounds like is happening.

Dan Ambrisco
  • 865
  • 7
  • 13
  • Ok, that makes sence. Ill go back and add both the www. and non www. versions with the same IP in the DNS. Thanks for your help. – Chris Feb 25 '12 at 02:30
0

Unless you do a dns change you can't do this. But after you have done that you can redirect www version to non www version or vice versa.

biztiger
  • 1,447
  • 4
  • 23
  • 40
0

It looks like you have a DNS entry for both www and non-www (maybe you just added it). Anyway, they both work. However, you should really pick one as the "standard", for seo reasons and just to be consistent. You can do this with .htaccess rules.

There are many questions and answers here on SO, such as:
Generic htaccess redirect www to non-www
This discusses both ways, depending which one you want.

Community
  • 1
  • 1
goodeye
  • 2,389
  • 6
  • 35
  • 68
  • Funny I thought I recognized the IP address... I used to host with them. – goodeye Feb 25 '12 at 02:36
  • Another question is how come you can see the non www one. For me its still propogating. – Chris Feb 25 '12 at 03:46
  • I'm guessing your local dns entries had the values that needed to expire. Since I had never visited it, I got the current records immediately. Just a guess. You can clear your local entries, which sometimes speeds things up (but then can depend if your ISP has the original values). See `ipconfig /flushdns`, and http://serverfault.com/questions/317083/having-problems-with-the-command-ipconfig-flushdns for windows 7 issues with it. (my server had crashed, so I moved to a datacenter closer to me, that's all.) – goodeye Feb 25 '12 at 23:30