从 Forms 身份验证中排除目录根目录
我正在使用 ASP.Net 表单身份验证来保护名为“pro”的目录。这一切都工作正常,但是我们想要做的是排除目录中的根页面 - 基本上这是一个详细介绍注册好处的销售页面。
所以,我的问题是是否可以保护目录,但排除该目录中的特定页面?
另一个选项似乎很简单,但就文件系统而言并不是特别整洁,它是构建我的目录,例如:
/pro/
/pro/default.aspx
/pro/ (secure anything within this folder)
/pro/loggedin/page1.aspx
/pro/loggedin/page2.aspx
任何帮助都非常感谢。 谢谢艾尔
I am using ASP.Net forms authentication to secure a directory called "pro". This is all working fine, however what we want to do is to exclude the root page within the directory - basically this is a sales page detailing the benefits of registering.
So, my question is whether it is possible to secure a directory, but exclude a particular page within that directory?
The other option, which seems pretty easy but not particularly tidy in terms of the file system is to structure my directories like:
/pro/
/pro/default.aspx
/pro/ (secure anything within this folder)
/pro/loggedin/page1.aspx
/pro/loggedin/page2.aspx
Any help greatly appreciated.
Thanks
Al
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果你想允许特定页面,那么它会像..
If you want to allow particular page, then it will be like..
要保护文件夹,请尝试以下操作:
To protect a folder, try the following: