开发者

IIS 7 and ASP.Net MVC issue

This is a bit complex - so here we go.

I am developing a mobile web application using asp.net mvc and I need to test it locally on my iPhone. So far I have the first iteritaion of the site running on my local dev laptop. I created a virtual dir for the site under IIS 7 on the same machine. I deployed the s开发者_运维知识库ite to that folder from VS2008. I open a browser and entered "" and the site cam up just fine. I am runnig a home network with locked down WIFI and both the laptip and my iPhone are on the network. So now I want to test with the iPhone but the site won't come up when browsing to "". I have another machine that is also on the network and I get this error message when attempting to browse to the site:

"Website (laptopname) is online but isn't responding to connection attempts"

I have a feeling that this has something to do with IIS setting and \ or application pools but have not been able to find anything relavent goolging. Any help appreciated.


There are some possibilities:

  1. iPhone is not able to resolve your laptop by name. Try using the IP address of your computer in the URL instead.
  2. The firewall on the laptop is blocking inbound connections from other machines. Check your firewall.
  3. The IIS Website is configured with a host header localhost so it won't respond to requests to other hostnames. Check the binding for the Web site in the IIS Manager.

To eliminate possible network issues, you can create an ad hoc WiFi network on your PC and connect to that network to test.


Check that Allow Anonymous Access is set for the site


I suspect you are not alone, as I had this exact problem. I developed a small port opener I called "SharpProxy" that may make your local testing much easier.

Overview and instructions: http://www.codefromjames.com/wordpress/?p=97

It's open source! Get code here: https://github.com/jocull/SharpProxy

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜