⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 membersaveinfo.asp

📁 修改迅易在线评选管理系统,,功能能用,下载的迅易功能不全,
💻 ASP
字号:
<% Option Explicit %>
<%Response.Charset="utf-8"%>
<!--#include file="../Include/Const.asp"-->
<!--#include file="../Include/ConnSiteData.asp"-->
<!--#include file="../Include/Md5.asp"-->
<!--#include file="../Include/Function.asp"-->
<%
dim ID,RealName,Sex,Password,vPassword,Company,Address,ZipCode,Telephone,Fax,Mobile,Email,HomePage,VerifyCode
dim rs,sql,rsRepeat
ID=request.QueryString("ID")
RealName=trim(request.form("RealName"))
Sex=trim(request.form("Sex"))
Password=trim(request.form("Password"))
vPassword=trim(request.form("vPassword"))
Company=trim(request.form("Company"))
Address=trim(request.form("Address"))
ZipCode=trim(request.form("ZipCode"))
Telephone=trim(request.form("Telephone"))
Fax=trim(request.form("Fax"))
Mobile=trim(request.form("Mobile"))
Email=trim(request.form("Email"))
HomePage=trim(request.form("HomePage"))
VerifyCode=trim(request.form("VerifyCode"))
dim ErrMessage,ErrMsg(8),FindErr(8),i
  ErrMsg(0)="·设置密码长度应为6-16个任意字符串"
  ErrMsg(1)="·设置密码和确定密码不一致"
  ErrMsg(2)="·单位名称、地址长度不能超过100个字符"
  ErrMsg(3)="·邮编长度不能超过20个字符"
  ErrMsg(4)="·真实姓名、电话、传真、移动电话、网址不能超过50个字符"
  ErrMsg(5)="·电子邮箱格式不正确"
  ErrMsg(6)="·电子邮箱已经被注册过"
  ErrMsg(7)="·验证码错误或已失效"
if len(Password)>0 then
  if not (6<=len(Password) and len(Password)<=16) then
    FindErr(0)=true
  end if
  if Password<>vPassword then
    FindErr(1)=true
  end if
end if
if len(Company)>100 or len(Address)>100 then
  FindErr(2)=true
end if
if len(ZipCode)>20 then
  FindErr(3)=true
end if
if len(RealName)>50 or len(Telephone)>50 or len(Fax)>50 or len(Mobile)>50 or len(HomePage)>50 then
  FindErr(4)=true
end if
if not IsValidEmail(Email) then
  FindErr(5)=true
else
  set rsRepeat = conn.execute("select MemName from ameav_Members where ID<>"&ID&" and Email='" & Email & "'")
  if not (rsRepeat.bof and rsRepeat.eof) then FindErr(6)=true
end if
if session("VerifyCode")<>VerifyCode then
  FindErr(7)=true
end if
for i = 0 to UBound(FindErr)
  if FindErr(i)=true then
    ErrMessage=ErrMessage+ErrMsg(i)+"<br>"
  end if
next
if not (ErrMessage="" or isnull(ErrMessage)) then
  WriteMsg(ErrMessage)
  response.end
end if
set rs = server.createobject("adodb.recordset")
sql="select * from ameav_Members where ID="&ID
rs.open sql,conn,1,3
rs("RealName")=StrReplace(RealName)
rs("Sex")=Sex
if len(Password)>0 then rs("Password")=Md5(Password)
rs("Company")=StrReplace(Company)
rs("Address")=StrReplace(Address)
rs("ZipCode")=StrReplace(ZipCode)
rs("Telephone")=StrReplace(Telephone)
rs("Fax")=StrReplace(Fax)
rs("Mobile")=StrReplace(Mobile)
rs("Email")=Email
rs("HomePage")=StrReplace(HomePage)
rs.update
rs.close
set rs=nothing
WriteMsg("·修改成功,点击查看<a href='MemberInfo.asp'><font color='red'>[我的资料]</font></a>。")
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -