2

I have purchased a GoDaddy Windows 2003 server, the problem is I can't access my site via localhost but it can be accessed via a URL. Can anybody tell me what should I look for?

ctype.h
  • 205
  • 1
  • 3
  • 11
Shishant
  • 683
  • 2
  • 8
  • 13

2 Answers2

3

I imagine this is because your site in IIS is set to use host headers, usually the default site in IIS is set to listen on all IP's, so that it will respond to a localhost request. To get your site to respond to local host you will need to get it to listen on 127.0.0.0 IP, and remove this from the default site.

Sam Cogan
  • 38,736
  • 6
  • 78
  • 114
0

I assume you have administrative control over server and you can interactively login to server and make changes.

Do this, say if you wanted to access your site as http://mysite

Find your server's IP address

Start > run > CMD.exe then in resulting command prompt type ipconfig /all

Make entry in HOSTS file Open c:\windows\system32\drivers\etc\hosts file and make entry x.x.x.x mysite where x.x.x.x is IP address you found from previous step

You are done, now access your site locally from server using http://mysite URL

KAPes
  • 994
  • 4
  • 12