StregSpiller
New Member
I'm working on an ASP.NET Web Forms application and where I've a folder called \[code\]Account\[/code\] at the root. Which contain mainly three ASPX pages: \[code\]Login.aspx\[/code\], \[code\]ChangePassword.aspx\[/code\], \[code\]ForgotPassword.aspx\[/code\].I've configured forms authentication with custom membership provider.web.config\[code\]<authentication mode="Forms"> <forms loginUrl="~/Account/Login.aspx" slidingExpiration="true" timeout="2880" path="/" protection="All" /></authentication><membership defaultProvider="CustomMembershipProvider"> <providers> <clear/> <add name="CustomMembershipProvider" type="App_Code.CustomMembershipProvider, Portal.Web" connectionStringName="PortalConnectionString" applicationName="/" /> </providers></membership>\[/code\]If I try to access the pages in \[code\]Account\[/code\] folder other than \[code\]Login.aspx\[/code\] I've been redirecting to \[code\]Login.aspx\[/code\] and I currently I'm avoiding forms authentication for the other two pages like below,\[code\] <location path="Account/ChangePassword.aspx"> <system.web> <authorization> <allow users="*"/> </authorization> </system.web> </location> <location path="Account/ForgotPassword.aspx"> <system.web> <authorization> <allow users="*"/> </authorization> </system.web> </location>\[/code\]Instead of specifying individual pages like above can I combine them? I tried of specifying the folder name \[code\]Account\[/code\] in the \[code\]path\[/code\] attribute but that's not working.The next thing is I've another page called \[code\]Dashboard.aspx\[/code\] in the root and whenever I directly access it I thought I would be redirected to the \[code\]Account/Login.aspx\[/code\] page but it's not happening, why?