How to access my asp.net MVC website on my local IIS server from my iPad (for testing)?

前端 未结 5 1772
臣服心动
臣服心动 2021-02-02 13:40

I\'m building an app using Visual Studio 2010. I can run my asp.net website from my computer (by pressing F5). I would like to run this website on my iPad for testing purpose.

5条回答
  •  甜味超标
    2021-02-02 14:16

    You are probably using the default Visual Studio Web Developer Server (Cassini) which doesn't allow one to access the site from anywhere else than the localhost.

    The easiest way around this is to change from the Web Developer Server to IIS Express. Here's a good tutorial by Scott Hanselman on how to do this. The only thing you really need to do is to click the Use IIS Express-button.

    Unfortunately, by default, the IIS Express doesn't allow external access but there's an easy way around this problem too. Here's question from Stack Overflow which points you to the correct solution. After following those instructions the IIS Express should server the site outside the localhost and you should be able to connect to the page using your IPad.

    Update:

    Here's an another blog post which shows how to edit the IIS Express to allow external access (Section 3).

提交回复
热议问题