<%@ Language=VBScript %> <% '判断用户是否登录 if isempty(Session("ID")) then Response.Redirect "../Login.asp" %> <% end if dim connstr,conn,rs,sql connstr="dbq="+server.MapPath("..\manage\manage\manage.mdb")+";defaultdir=;driver={microsoft access driver (*.mdb)};" set conn=server.CreateObject("adodb.connection") conn.Open connstr set rs=server.CreateObject("adodb.recordset") sql="select * from PSLogins" rs.open sql,conn,1,3 '连接系统数据库 'set conn = server.createobject ("adodb.connection") 'conn.open "ASPData", "sa", "yourpassword" '如果用户提交了表单 if not IsEmpty(Request.Form("Send")) then '进行用户身份校验 if Request.Form("Password") = Session("Password") then if len(Request.Form("NewPassword"))=0 then Session("EmailAddress")=Request.Form("EmailAddress") Session("InternalPhone")=Request.Form("InternalPhone") Session("HomePhone")=Request.Form("HomePhone") Session("MobilePhone")=Request.Form("MobilePhone") Session("QQ")=Request.Form("QQ") Session("HomeAddress")=Request.Form("HomeAddress") Session("Birthday")=Request.Form("BirthdayYear") & "-" & Request.Form("BirthdayMonth") & "-" & Request.Form("BirthdayDay") '更新用户个人信息 conn.Execute " update PSLogins set " _ & "EmailAddress='" & Request.Form("EmailAddress") & "', " _ & "InternalPhone='" & Request.Form("InternalPhone") & "', " _ & "HomePhone='" & Request.Form("HomePhone") & "', " _ & "MobilePhone='" & Request.Form("MobilePhone") & "', " _ & "QQ='" & Request.Form("QQ") & "', " _ & "HomeAddress='" & Request.Form("HomeAddress") & "', " _ & "Birthday='" & Request.Form("BirthdayYear") & "-" _ & Request.Form("BirthdayMonth") & "-" _ & Request.Form("BirthdayDay") & "' " _ & " Where Name='" & Request.Form("Name") &"'" TheMessage = "您的个人信息已经修改成功" else '如果用户输入了新密码 if Request.Form("NewPassword") = Request.Form("ConfirmNewPassword") then Session("Name") = Request.Form("Name") Session("Password") = Request.Form("NewPassword") Session("EmailAddress")=Request.Form("EmailAddress") Session("InternalPhone")=Request.Form("InternalPhone") Session("HomePhone")=Request.Form("HomePhone") Session("MobilePhone")=Request.Form("MobilePhone") Session("HomeAddress")=Request.Form("HomeAddress") Session("Birthday")=Request.Form("BirthdayYear") & "-" & Request.Form("BirthdayMonth") & "-" & Request.Form("BirthdayDay") Session("QQ")=Request.Form("QQ") Session("HomeAddress")=Request.Form("HomeAddress") conn.Execute " update PSLogins set " _ & "Password='" & Request.Form("NewPassword") & "', " _ & "EmailAddress='" & Request.Form("EmailAddress") & "', " _ & "InternalPhone='" & Request.Form("InternalPhone") & "', " _ & "HomePhone='" & Request.Form("HomePhone") & "', " _ & "MobilePhone='" & Request.Form("MobilePhone") & "', " _ & "QQ='" & Request.Form("QQ") & "', " _ & "HomeAddress='" & Request.Form("HomeAddress") & "', " _ & "Birthday='" & Request.Form("BirthdayYear") & "-" _ & Request.Form("BirthdayMonth") & "-" _ & Request.Form("BirthdayDay") & "' " _ & " Where Name='" & Request.Form("Name") &"'" TheMessage = "您的个人信息已经修改成功" else TheMessage = "新密码输入不一致,请重试" end if end if else TheMessage = "您输入的密码有误,请重试" end if else TheMessage = "请在下面修改您的个人信息" end if %> 用户资料修改
收藏本页
 
[当前用户- <% response.write Session("Name") %> ]
返回菜单  关闭退出 
请您正确填写以下信息以方便我们之间的联系!
业务员姓名 " SIZE=25 MAXLENGTH=50 > * (此项不允许修改)
电子邮件 " SIZE=51 MAXLENGTH=50 >
公  司 " SIZE=51 MAXLENGTH=50 >
联系电话 " SIZE=51 MAXLENGTH=50 >
其它 " SIZE=51 MAXLENGTH=50 >
其它 " SIZE=51 MAXLENGTH=50 >
日期 日  
备注 " SIZE=51 MAXLENGTH=50 >
请输入您旧的密码 * (修改时必须填上您的旧密码)
新密码输入
新密码确认