What is the use of location tag in web.config file

Answer Posted / asif ismail kunnibhavi

configuration setting is applied to specific file/folder
with appropriate "Path" attribute.
e.g
1)applying setting to everything under System.web
<location path="Administrator" >
<system.web>
<authorization>
<deny users="?" />
<allow roles="Administrator" />
<deny users="*" />
</authorization>
</system.web>
</location>

2)applying setting to specific directory called "folder1"

<!— Configuration for the "folder1" subdirectory. -->
<location path="sub1">
<system.web>
<httpHandlers>
<add verb="*" path="folder1.Scott"
type="folder1.Scott"/>
<add verb="*" path="folder1.David"
type="folder1.David"/>
</httpHandlers>
</system.web>
</location>

Is This Answer Correct ?    17 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of server controls do we have?Also explain differance between them taking an example of ASP.NET?

2362


How Session outproc in Sqlserver stored?

2303


Where you store Connection string in "Web.Config" file in ASP.NET?

580


How many ways are there to maintain a state in .net? What is view state?

588


Mention the execution process for managed code?

535






What are the different types of sessions in asp.net? Name them?

674


what are configuration files?

561


What are the asp.net list controls and difference between them?

512


What tags do you need to add within the asp:datagrid tags to bind columns manually? Give an example.

599


How to sign out from forms authentication?

539


How to create discussion forum in asp.net mvc? : Asp.Net MVC

531


What is data control in asp.net?

512


How do you create a master page?

549


What are the namespaces used in asp.net mvc? : asp.net mvc

511


What is comparevalidator?

521