I am developing an e-commerce practice test web site. Only registered users can access the full version of the practice tests. All full version of the practice test code and pages are in a subfolder of the app root called 'Test'
Basically, I want to secure only the 'Test' subfolder and all of its contents with forms authentication. I tried using the following in my Web.config file at the app root:
[tt]
<location path="Test">
<system.web>
<authentication mode="Forms" />
</system.web>
</location>
[/tt]
and I tried adding a second web.config file to the 'Test' subfolder itself. Both approaches yielded the same error message:
[tt]
It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
[/tt]
Does this mean I have to bust my web app into more than one virtual folder in IIS? I'm hoping that there is an alternative since the .NET documentation hints at being able to do this without actually saying how.
Basically, I want to secure only the 'Test' subfolder and all of its contents with forms authentication. I tried using the following in my Web.config file at the app root:
[tt]
<location path="Test">
<system.web>
<authentication mode="Forms" />
</system.web>
</location>
[/tt]
and I tried adding a second web.config file to the 'Test' subfolder itself. Both approaches yielded the same error message:
[tt]
It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
[/tt]
Does this mean I have to bust my web app into more than one virtual folder in IIS? I'm hoping that there is an alternative since the .NET documentation hints at being able to do this without actually saying how.