网站认证技术 [英] website authentication technique

查看:105
本文介绍了网站认证技术的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道该怎么问,但我会问你我能最好地解释的方式,我想添加一个用户名和密码来登录网站,而当用户名和密码正确时,它必须转到其他页面其他错误错误.但是登录后,如果我们复制URL,然后再次登录,则可以直接复制过去的URL,而无需登录.但我希望用户始终登录,是指重定向的URL(如果直接粘贴),页面应要求用户名和密码,就像我们在facebook或google中所看到的那样(网站)

i don''t know how exactly to ask question but i will ask you the way i can best explain and i want to add an username and pwd to login to website and when username and pwd is correct it has to divert to other page else wrong error. but after loging in if we copy the url and next time if we want to login we can directly copy past the previous url only there is no need to login rite..?? but i want the user to login always i mean the redirected url if it is pasted directly the page should ask for username and pwd as we can see in facebook or google like websites

推荐答案

从这里开始:
http://msdn.microsoft.com/en-us/library/eeyk640h.aspx [ ^ ].

—SA
Start here:
http://msdn.microsoft.com/en-us/library/eeyk640h.aspx[^].

—SA


朋友.....

首次登录时,您将在会话>>>中保存UserID.好的

之后,必须在每个页面中检查UserID是否为空
如果(UserID == null)
//检查用户名和密码,下一次填充会话
其他
//重定向到欢迎页面


因此对于网站中的所有页面,此代码必须重复,因此您可以选择将先前的代码放入BasePage中,并且网站中的所有页面都继承 BasePage
形式
在每个页面中的命名空间之后,我们都有:

PageName:基本页面
Friend.....

when you LogIn first time you will save UserID in session >>> ok

after that in every page must check for UserID is null or not
if (UserID == null)
// Check for Username and Password , next fill session
else
// Redirect to welcome page


so this code must repeated for all pages in website, so you have option that you can put previous code in BasePage and All pages in website inherits form BasePage

after namespace in every page we have :

PageName : Basepage


您可以通过遵循SAKrukov建议的站点来实现该解决方案,您必须在应用程序中实现Forms身份验证,然后才有可能进行解释.
有关更多信息,请参见:
http://msdn.microsoft.com/en-us/library/ff647070.aspx [ ^ ]
http://support.microsoft.com/kb/301240 [
you can achieve the solution by following SAKrukov suggested site , you have to implement Forms authentication in your application then only it is possible that you explained.
for more refer:
http://msdn.microsoft.com/en-us/library/ff647070.aspx[^]
http://support.microsoft.com/kb/301240[^]


这篇关于网站认证技术的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆