【问题标题】:accessing an iis localhost path from another computer on the network从网络上的另一台计算机访问 iis localhost 路径
【发布时间】:2016-03-22 14:33:33
【问题描述】:

我在 Visual Studio 2015 中有一个 Web 应用程序项目。我在本地 iis 上使用http://localhost/WebApplication1 URL 构建了它。我可以使用上面的 url 从我的计算机访问该项目,但我无法从我直接连接到此的另一台计算机访问。

我检查了这些:

1.I can share folders from these computers.
2.I make a rule in firewall for port 80 inbound
3.I checked vs debug remote allowed in firewall
4.I checked "ping localhost" and it received ping

我使用带有 iis express 6 的 windows 10

【问题讨论】:

  • 你可以使用 http://[machinename]/WebApplication1 或 http://[IP_of_machine]/WebApplication1
  • 也为我解决了同样的问题,谢谢!

标签: asp.net visual-studio iis


【解决方案1】:

IIS Express 最初设计为仅处理本地请求以用于调试和开发目的。尽管您可以打开它并通过一些调整向您的网站提供外部请求。

在位于%userprofile%\documents\iisexpress\config 的文件applicationhost.config 中,将您的localhost 更改为*,甚至您的机器名称。

否则为什么不安装 IIS,它允许对站点进行比 express 更多的调整?

How to Install IIS on Windows 8 or Windows 10

【讨论】:

  • 首先我尝试了iis虚拟目录将我的项目放入其中。我设置了Sitename:Webapp,物理路径:项目在哪里,类型:http,IP地址:All Unassigned,端口:80,主机名称:本地主机,但当我浏览 web 应用程序时,它什么也没显示!有什么问题?
  • 你重启了吗?
  • 是的。我重新启动它。但是当我在右窗格中单击 *:80 (http) 上的 Brows localhost 时,我只是面对一个空白页面
  • 这是一个模糊的答案,为什么会否决。请准确说出将 localhost 更改为 * 的位置。我在提到的文件中只找到了一个 localhost 实例并对其进行了更改,但没有任何效果。
  • 您很可能遇到了不同的问题,因此无法猜测您的情况会发生什么。您应该发布您自己的问题,并附上提供的相关要点和一个可重复性最低的示例。
猜你喜欢
  • 2012-05-22
  • 2015-08-06
  • 2020-03-20
  • 2015-02-10
  • 2016-09-15
  • 2020-08-24
  • 2019-01-03
  • 2020-07-06
  • 2013-10-29
相关资源
最近更新 更多