How to Stop Web.config Inheritance into Child Application/Directories

If you are running a site which may have an application at the root
and other separate applications running in sub or virtual directories,
then Settings of web.config inheritance could be a problem, this can be
overcome by using location tag in root web.config


The
following example shows how to use this attribute in a configuration
file to specify that the settings defined in the location element for
the root of a Web site should not be inherited by child applications:

<location path="." inheritInChildApplications="false">
<system.web>
 …
</system.web>
</location>

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s