<%dbdns="../../"%>
<!--#include file="../main.asp"-->
<!--#include file="../Include/md5.asp" -->
<%
txtUserName=request.QueryString("txtUserName")
txtPassword=request.QueryString("txtPassword")
realname=request.QueryString("realname")
coname=request.QueryString("coname")
txtEmail=request.QueryString("txtEmail")
addone_id=request("addone_id")
addtwo_id=request("addtwo_id")
set rs=Server.CreateObject("Adodb.Recordset")
rs.Open "Select *  from T_Member where F_UserName='"&txtUserName&"'",conn
if not rs.EOF then
Response.Write "<script>alert('用户注册出错，下面是产生错误的可能原因：\n\n·对不起，该用户名已经存在，请重新选择');history.go(-1);</Script>"
Response.End   
end if
'///////////////////////////////////////////
set rs=Server.CreateObject("Adodb.Recordset")
sql="select * from T_Member"
rs.open sql,conn,1,3
rs.addnew
rs("F_username")=txtUserName
rs("F_password")=md5(txtPassword)
rs("F_realname")=realname
rs("F_coname")=coname
rs("F_Email")=txtEmail
rs("F_ypaddone")=addone_id
rs("F_ypaddtwo")=addtwo_id
rs.update
rs.close
set rs=nothing
response.Redirect("../index.asp")
response.End()
%>