Is there a way to add a virtual directory to Visual Studio Development Server?

谁说胖子不能爱 提交于 2019-12-01 02:17:16

The Visual Studio Development Server is codenamed Cassini.

From ASP.NET 2.0: A Getting Started Guide

Cassini doesn't support virtual directories, security settings,  or any of IIS's other fancy features; it's just a very simple web server  that gives you the basics you need to get up and running. 

I am using the IIS which is included with Windows XP Pro. It only allows one website without tweaking but does have virtual directories. If you are on Vista, you can setup multiple sites in IIS from what I have heard.

Darin Dimitrov

Yes, you can specify a virtual path such as /foo instead of / in the properties of your project:

The closest you can get to virtual directories in the Visual Studio Development Server is by using OS symlinks to map a directoty outside of the Web site root to a path within the root
http://en.wikipedia.org/wiki/NTFS_symbolic_link

Yes, you can provide a physical path by launching it through command line

C:\Program Files (x86)\Common Files\microsoft shared\DevServer\9.0\Webdev.WebServer.exe /port:9081 /path:C:\temp\vdir 

just do /? for a list of command line options

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!