判断下是否有重复的JOBID,重复就再生成下次!
set rs=server.createobject("adodb.recordset")
sql="select * from [ijob_person] where username='"&trim(request("username"))&"' or useremail='"&trim(request("useremail"))&"'"
rs.open sql,conn,1,3
if not rs.eof then
response.write "<br>"+"<li>对不起该用户已经存在!请返回重新输入资料!"
response.end
else
rs.addnew
rs("username")=trim(request("username"))
'---------------------------------------------------
rs("jobid")=gen_key(10)
'---------------------------------------------------
rs("password")=trim(request("password"))
rs("useremail")=trim(request("useremail"))
rs("zazhi")=request("zazhi")
rs("zcdata")=NOW()
rs("ip")=Request.serverVariables("remote_addr")
rs("name")=request("name")
rs("xingbie")=request("xingbie")
rs("minzu")=request("minzu")
rs("xueli")=request("xueli")
rs("hunyin")=request("hunyin")
rs("age")=request("age")
rs("xuexiao")=request("xuexiao")
rs("zhuanye")=request("zhuanye")
rs("x_suozaidi")=request("x_suozaidi")
rs("x_suozaidi1")=request("x_suozaidi1")
rs("huji")=request("huji")
rs("huji1")=request("huji1")
rs("shengao")=request("shengao")
rs("birthyear")=request("birthyear")
rs("birthmonth")=request("birthmonth")
rs("birthday")=request("birthday")
rs("dianhua")=request("dianhua")
if request("qq")="" then
rs("qq")=0
else
if not isnumeric(request("qq")) or len(request("qq"))>15 then
response.write "<br>"+"<li>QQ号码要求只能填写不大于15位的数字。"
response.end
else
rs("qq")=request("qq")
end if
end if
rs("gerenzhuye")=request("gerenzhuye")
rs("pingjia")=request("pingjia")
rs("jinengzhuanchang")=request("jinengzhuanchang")
rs("selectedjob1")=request("selectedjob1")
rs("selectedjob2")=request("selectedjob2")
rs("selectedjob3")=request("selectedjob3")
rs("s_PWL1")=request("s_PWL1")
rs("s_PWL2")=request("s_PWL2")
rs("s_PWL3")=request("s_PWL3")
if request("daiyuyaoqiu")="" then
rs("daiyuyaoqiu")=0
else
if not isnumeric(request("daiyuyaoqiu")) then
response.write "<br>"+"<li>待遇要求只能填写数字。"
response.end
else
rs("daiyuyaoqiu")=request("daiyuyaoqiu")
end if
end if
if person_rz=1 then
rs("administrator")=0
else
rs("administrator")=1
end if
rs("Negotiable")=request("Negotiable")
rs("provideHouseNeeded")=request("provideHouseNeeded")
rs("availOpts")=request("availOpts")
rs("availNotice")=request("availNotice")
rs("jiaoyubeijing")=request("jiaoyubeijing")
rs("dlsj")=now()
rs("xgsj")=now()
rs.update
session("reg")=now()
end if
rs.close
set rs=nothing
call closedb
session("reg")=""
response.write "<br>"+"<li><font color=""#ff0000"">注册成功,请等待管理员审核资料!</font>"
response.write "<br>"+"<li>正在进入首页...请稍等!!!!!"
response.write "<meta http-equiv=refresh content=""1;URL=../index.asp"">"
%>