54 lines
1.8 KiB
C#
54 lines
1.8 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
|
|
namespace Mtxfw.VipSite
|
|
{
|
|
public partial class Member_IFPassword : Mtxfw.Utility.MemberBase
|
|
{
|
|
public Mtxfw.DAL.user_info daoUser = new Mtxfw.DAL.user_info();
|
|
public Mtxfw.Utility.Config config = new Mtxfw.Utility.Config("");
|
|
public int gtype = 0;
|
|
protected override void OnLoad(EventArgs e)
|
|
{
|
|
base.OnLoad(e);
|
|
string hostname = Request.Url.Host;
|
|
|
|
if (IFStores == 1)
|
|
{
|
|
if (GoToMemberId > 0)
|
|
{
|
|
Card = GoToMemberId;
|
|
IFStores = 0;
|
|
}
|
|
}
|
|
if (!IsPostBack)
|
|
{
|
|
Page.Title = "输入二级密码 - " + config.webName;
|
|
|
|
}
|
|
|
|
Btn_Update.Click += Update_Password;
|
|
}
|
|
|
|
protected void Update_Password(object s, EventArgs ex)
|
|
{
|
|
Mtxfw.Model.user_info model = daoUser.GetModel(Card);
|
|
if (!String.IsNullOrEmpty(Text_oPwd.Text))
|
|
{
|
|
if (Mtxfw.Utility.Security.EncryptString(Text_oPwd.Text) == model.Password2)
|
|
{
|
|
Session["IFPassword"] = 0;
|
|
if (Request.QueryString["Url"] != null)
|
|
{
|
|
Response.Redirect(Request.QueryString["Url"].ToString());
|
|
}
|
|
}
|
|
else ClientScript.RegisterStartupScript(this.GetType(), "", "<script type='text/javascript'>alert('密码输入错误哦!')</script>");
|
|
}
|
|
else ClientScript.RegisterStartupScript(this.GetType(), "", "<script type='text/javascript'>alert('不能提交空值!')</script>");
|
|
}
|
|
}
|
|
} |