Is it possible to completely negate a web.config in a subfolder?
Obviously, I have a web.config in the root.
If I have a subfolder called "MyApp", can I write a bunch of code in there and have it run without any reference to the web.config at root? It would have its own web.config, and wouldn't even reference the "higher" web.config in root.
What I'm looking for is complete App isolation. I'd like to be able to write an app in a subfolder of an existing site, which ignores the entire web.config hierarchy above it -- the app would an island all to itself.
I know I can use the "clear" element, but is that the best way? Just put a "clear" under every top level element? Just wondering if there's another way.
Duplicate of Will a child application inherit from its parent web.config?
On the web.config file in the root directory, wrap the <system.web>
element with the following element: <location path="." inheritInChildApplications="false"></location>
Check out this link for a reference:
http://www.jaylee.org/post/2008/03/Prevent-ASPNET-webconfig-inheritance-and-inheritInChildApplications-attribute.aspx
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With