示例网站登录/注册码?
我正在考虑构建网站 (ASP.NET) 的登录/注册部分,并希望看到一些示例代码或有关如何正确执行此操作的说明。例如,如何正确使用 cookie 以及如何对 cookie 中存储的内容进行加密,以确保会话持续存在,直到注销/超时。
我不想使用内置的 ASP.NET Membership/Provider 内容,因为它看起来使用起来很痛苦并且不太灵活。请不要回答“ASP.NET Membership/Providre 的东西使用起来是多么简单,只需检查一下,您就会使用它!”因为我不想用它!
I am looking at building the login/registration part of a website (ASP.NET) and would like to see some example code or instructions on how to do this properly. For example, how to correctly use cookies and how to encrypt what is stored in the cookie to ensure the session persists until they logout/timeout.
I do not want to use the builtin ASP.NET Membership/Provider stuff as it looks painful to use and not very flexible. Please do not answer with 'This is how easy the ASP.NET Membership/Providre stuff is to use, just check this out and you will use it!' as I don't want to use it!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
不要误会我的意思,我只是想知道您到底觉得 ASP.NET 提供程序的哪些方面令人痛苦且不灵活?我经常使用它们并且发现它们非常灵活。我什至编写了一些自定义提供程序,这是一个简单的过程。
如果您不想使用 ASP.NET 提供程序,您的具体要求是什么?如果我更好地理解你想要实现的目标,我可能会帮助你。
迈克尔
Don't get me wrong, I'm just wondering what exactly do you find painful and not flexible about the ASP.NET providers? I've used them a lot and I find them very flexible. I've even written some custom providers which is a straight forward process.
If you don't want to use ASP.NET providers, what are your exact requirements? I might help you out if I understand a bit better what you are trying to achieve.
Michael