<!--#include file="../inc/Bll.asp"-->
<!--#include file="../inc/Constant.asp"-->
<!--#include file="../inc/Md5.asp"-->
<!--#include file="../inc/App.asp"-->
<%
Auto_Login()

'注册验证
LocalValid
'整合应用登录
i_Syn_Notify_Modify_PassOrMail Session(Session_UserName_Arg),t_NewPass,""
'本地数据登录
LocalModify

dim t_OldPass,t_NewPass,t_GoUrl
'本地数据验证
Sub LocalValid()
	'验证数据
	if request.form("ac")<>"Modify" then Rws "alert('非法请求!');":Rend
	t_OldPass = CheckSub(vPwd,request.form("OldPass"),"旧密码格式有误") '验证密码
	t_NewPass = CheckSub(vPwd,request.form("NewPass"),"新密码格式有误") '验证密码
	t_GoUrl = Get_SafeStr(Request.form("GoUrl"))
End Sub

'本站数据注册
Sub LocalModify()
	RS_End
	RS.OPEN "select top 1 * from [i_User_Info] where [i_User_Pass]='"&MD5(t_OldPass)&"' and [i_User_ID]="&Session(Session_UserID_Arg) , DB_CONN , 1 , 3
	if RS.recordcount>0 then
		if RS("i_User_IsLock")=1 then Rws "alert('您的账户已被锁定,请联系管理员!');history.back();":Rend
		'验证成功
		RS("i_User_Pass") = MD5(t_NewPass)
		RS.Update()
		RS_End
		RWS "alert('密码修改成功！');location.href='"&Request.Form("GoUrl")&"';"
		Rend
	else
		RWS "alert('密码错误！');history.back();":Rend
	end if
End Sub

%>