User2094731468 posted
The scenario is :
I am working on role based project in vs2005 and sql server2005. I defined the role in database and added custom role provider. I have two roles like "admin" and "user". I created two folder in project and placed the pages in these folder (admin and user)
according to roles. Now I want to add code in web.config for accessing the pages according to roles means admin can see only admin folder pages and user can see only user folder pages.
If I define only one page for admin and one page for user in tag with roles authorization then they work fine. But if I used more than one pages in both folder then I need to define all pages in web.config file for both.
I used ` tag like this
<location path="user/userpage1.aspx"> <system.web> <authorization> <allow roles="user"/> <deny users="*"/> </authorization> </system.web> </location>
Is there any possibility to assign a role for a folder instead of a page in tag. If yes, Please give some valuable ideas to implement this.