views:

14

answers:

1

I'm a bit confused.
When I type in my browser a "local" address (of a web site I'm editing on VS), IIS can handle it. How is that so? How can IIS know what's my latest web site version? What's the difference between typing the address in the browser and compiling the web site, and what does localhost has to do with all of that? And last one - is the IIS on my machine accessible to other computers on the net?
Edited the last one..

Thanks a lot.

+1  A: 

localhost is an alias for the loopback address 127.0.0.1. It's not actually hard-coded; you can find it in C:\WINDOWS\system32\drivers\etc\hosts.

Pointing your browser to http://localhost/... will open port 80 on your local machine, which is the port IIS listens on by default. IIS doesn't actually know your website's latest version. It will simply find whatever assemblies and other files it has been directed to use, in whatever state they are in. Compiling will generate new assemblies to match your latest code, and IIS will pick those new assemblies up on the next request that hits the site.

The localhost address isn't accessible from other machines. They will almost certainly have the same alias, pointing to their loopback interface.

Marcelo Cantos