views:

53

answers:

1

Hello,

I have several ASP.NET applications in virtual folders (already configured as applications, and with different application pools), but I want to install another ASP.NET application that will redirect to one of the virtual folders according to some criteria (from database and cookies).

All the applications in the virtual folders work fine, but if I install the root application, then I get some errors about duplicate web.config settings.

A workaround would be to create yet another virtual folder for the redirecting application, and use HTML redirection on the root site.

However, I would like to know if it is possible for a web application in a virtual folder to skip the website-root web.config in the .config hierarchy.

Thanks,

Luis Alonso Ramos

+1  A: 

One option is to move all the settings of the web.config to a location path where you use the inheritInChildApplications attribute so that those settings are only applied for the parent application and not child applications, something like:

<location inheritInChildApplications="false">
... move all your settings here...
</location>
CarlosAg