Mobile app version of vmapp.org
Login or Join
Hamaas447

: Localhost vs 127.0.0.1 - Error when referring to own IP address for an application running on IIS I have an ASP.net application which I've been playing around with on my Windows 2008 server.

@Hamaas447

Posted in: #AspNet #IpAddress #Localhost #WindowsServer2008 #Wordpress

I have an ASP.net application which I've been playing around with on my Windows 2008 server. I have WordPress installed so that when I visit the server by it's IP address I can visit my hosted website.

The WordPress website works fine when I request the site by it's IP, but when I try to debug the ASP.net application in visual studio it opens localhost:49219/, where I can see my asp.net website, but even after opening this port and trying to access my application over the net by my server's IP I get the following error:



What is strange is that even on my server, I cannot visit the site by typing in 127.0.0.1:49219/.

I'd like to try to get this application on the net but I really have no clue why I can refer to it using localhost but not by IP. Any suggestions?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Hamaas447

1 Comments

Sorted by latest first Latest Oldest Best

 

@Hamaas447

After playing around for some time, I think I figured it out. The service I was running was on visual studio's debug server, so it was probably redirecting the request for localhost on that port to itself, however 127.0.0.1 probably can't be remapped in the same way. Everything worked correctly after the site was published.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme