MiMa.Asp
资源名称:4.rar [点击查看]
上传用户:zhbanny
上传日期:2020-11-04
资源大小:161k
文件大小:2k
源码类别:
手机WAP编程
开发平台:
ASP/ASPX
- <!--#Include File="../Inc/Head.Asp"--><%
- Private FangWen,c,s
- Call H_Title("修改密码")
- Set FangWen=New xkon_FangWen
- FangWen.FangWen()
- FangWen.Admin_MiMa()
- Set FangWen=Nothing
- Set c=New xkon_Response
- Set s=New xkon_Request
- Private MiMa_1,MiMa_2,MiMa_3,Cn1,Cn2
- MiMa_1=s.Form_aa("MiMa_1",4,16)
- MiMa_2=s.Form_aa("MiMa_2",4,16)
- MiMa_3=s.Form_aa("MiMa_3",4,16)
- If MiMa_1="" Or MiMa_2="" Or MiMa_3="" Then
- Else
- If Len(MiMa_1)>16 Or Len(MiMa_2)>16 Or Len(MiMa_3)>16 Or Len(MiMa_1)<4 Or Len(MiMa_2)<4 Or Len(MiMa_3)<4 Then
- c.Writeln("密码不能小于四位大于十六位")
- Else
- If MiMa_2<>MiMa_3 Then
- c.Writeln("密码与确认密码不相同")
- Else
- Call OpenData()
- Set Cn1=Server.CreateObject("ADODB.Command")
- Cn1.ActiveConnection=Conn
- Cn1.CommandType=1
- Cn1.CommandText="SELECT ID FROM ADMIN WHERE ZHANGHAO='"&Request.Cookies("AdminZhangHao")&"' And MIMA='"&MiMa_1&"'"
- Set Cn2=Cn1.Execute
- If Cn2.Eof Then
- c.Writeln("原密码输入错误")
- Else
- Conn.Execute("UPDATE ADMIN SET MIMA='"&MiMa_2&"' WHERE ZHANGHAO='"&Request.Cookies("AdminZhangHao")&"'")
- c.Writeln("修改成功")
- Call JiLu("修改密码")
- End If
- Set Cn2=Nothing
- Set Cn1=Nothing
- Call CloseData()
- End If
- End If
- End If
- c.Write("<form method=""post"" action=""MiMa.Asp"">")
- c.Writeln("原密码:<input type=""text"" name=""mima_1""/>")
- c.Writeln("新密码:<input type=""text"" name=""mima_2""/>")
- c.Writeln("确认新密码:<input type=""text"" name=""mima_3""/>")
- c.Write("<input type=""submit"" value=""修改""/>")
- c.Write("</form>")
- Call H_End()
- Set c=Nothing
- Set s=Nothing
- %>