ASP.NET Web Configuration
You can do this by creating a Web Setup project. In the File System, add as many web folders as you need.
Only the main web application folder will have an installation dialog, so if you want to customize the names of the virtual directories you will need to add a screen and set the web custom folder property to the same as the field name on the screen you are adding.
source to share
I've never found the whole concept of a "web customization project" to work well. To begin with, I've never managed a web server where the only site configuration was the default website, so the out-of-the-box functionality for defining a virtual directory to be created on the default site never worked for me, and it doesn't seem like that it would be very helpful to you.
The best option I have found is to create a standard setup project that sets the output files + content of each website to \\ sitepath (or similar) and records a custom installer action with a GUI-enabled installer that allows the (user) installer to select the correct website and specify the name of the virtual directory to be used.
source to share
As John Hunter said, it is possible to add multiple custom web folders for default websites for the default web applications folder. But you need to know some details about how things are going.
Note that the name Property
you set for the additional folder will be the physical installation path. This, however, only reads in your install logic, because it is automatically installed later when the IIS default path location is (usually C:\intepub\wwwroot\
) added with the value specified in the VirtualDirectory
folder properties. So, what you need to set on the custom screen you add is not the name Property
defined in the folder, but the property name that is used for the virtual directory. This nameProperty
that you specified in the VDIR application. Therefore, if the property name you specify for the web folder is "WEBSITE1" then the property name for the virtual folder will be "WEBSITE1VDIR". On your custom screen, you need to set up the property name for the text box you are using for "WEBSITE1VDIR". The default value in this text box will be automatically populated with the default VirtualDirectory specified in this folder.
If you decide to remove the default dialog to Installation Address
also specify the main website in a custom text box on the same page as the others, you need to know that the property name for the physical path as you see is grayed out to "TARGETDIR" in name Property
for "Web Application Folder". However, the property for the virtual path is not "TARGETDIRVDIR" as it would if it matched the same name as the other, but it is "TARGETVDIR".
But if you remove the Installation Address
default dialog box , you lose the ability to select the website to use (usually "Default Website") and the application pool from the drop-down lists that show you what's available.
source to share