VS Login登录控件实现登录认证
(2013-01-23 21:52:43)
标签:
vs2010loginit |
分类: 编程技法 |
HTML:
RenderOuterTable="false"
onauthenticate="LoginUser_Authenticate">
ValidationGroup="LoginUserValidationGroup "/>
CS文件注册一个事件外加一个赋值即可:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class Account_Login : System.Web.UI.Page
{
protected void Page_Load(object sender,
EventArgs e)
{
RegisterHyperLink.NavigateUrl
= "Register.aspx?ReturnUrl=" +
HttpUtility.UrlEncode(Request.QueryString["ReturnUrl"]);
}
protected void LoginButton_Click(object
sender, EventArgs e)
{
}
protected void LoginUser_Authenticate(object
sender, AuthenticateEventArgs e)
{
//此处省略代码200行
e.Authenticated =
true;
}
}
CS文件注册一个事件外加一个赋值即可:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class Account_Login : System.Web.UI.Page
{
}
前一篇:冰雪路面驾驶技巧

加载中…