简体   繁体   English

Visual Studio将我的本地IIS网站配置为ASP.NET网站

[英]Visual Studio configures my local IIS website as an ASP.NET website

We are using Visual Studio 2008 on IIS 7, and on some machines we are having trouble getting Visual Studio to recognize our website as an IIS website. 我们在IIS 7上使用Visual Studio 2008,并且在某些计算机上,我们无法使Visual Studio识别我们的网站为IIS网站。 On most machines it is configured properly, displaying and running under http://localhost/websitename . 在大多数计算机上,它已正确配置,可以在http:// localhost / websitename下显示和运行。 But on a couple of machines - using the same solution file - it loads it as a directory/asp.net site: in VS it appears as c:...\\foldername, and when running it, it comes up as http://localhost:randomportnumber/websitename . 但是在几台机器上-使用相同的解决方案文件-它将其加载为目录/asp.net站点:在VS中,它显示为c:... \\ foldername,在运行时,它显示为http:/ / localhost:randomportnumber / websitename

We tried removing and then re-adding the site through the File-> Open Website-> Local IIS, but when we select the site it automatically changes it to a asp.net site. 我们尝试通过“文件”->“打开网站”->“本地IIS”删除然后重新添加该站点,但是当我们选择该站点时,它将自动将其更改为asp.net站点。

Thanks in advance. 提前致谢。

在项目的属性中,可以指定是否使用IIS或内置的ASP.NET服务器。

When you debug a website and you see the odd port number after local, you are running the visual studio web server Cassini and not through IIS. 当您调试网站并在本地后看到奇数端口号时,您正在运行Visual Studio Web服务器Cassini,而不是通过IIS。

You can configure this when you go to property settings on your website. 您可以在网站上转到属性设置时进行配置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM