代码如下:
reg.asp:
===================
zp.css
/* CSS Document */
body {font-family:"宋体"; font-size:12px; color:#333333; line-height:20px;}
a:link {color: #333333;text-decoration: none;}
a:visited ,a:active {text-decoration: none;color: #333333;}
a:hover {text-decoration: underline;color: #003278;}
a.blue12:link {color: #001D4C;text-decoration: none;}
a.blue12:visited ,a.blue12:active {text-decoration: none;color: #001D4C;}
a.blue12:hover {text-decoration: underline;color: #FF6600;}
a.black14:link {color: #333333;text-decoration: none; font-size:14px; font-weight:bold; line-height:24px;}
a.black14:visited ,a.black14:active {text-decoration: none; font-size:14px; font-weight:bold;color: #333333; line-height:24px;}
a.black14:hover {text-decoration: underline;color: #FF6600;font-size:14px; font-weight:bold; line-height:24px;}
a.title_kh:link ,a.title_kh:visited {color: #333333;text-decoration: none;}
a.title_kh:hover { text-decoration: none;color:#FF6600; font-size:120%;}
a.title_kh:active {text-decoration: none; color:#FF6600;}
a.yellow:link ,a.yellow:visited {color: #FF6600;text-decoration: none;}
a.yellow:hover { text-decoration: underline;color:#003278; }
a.yellow:active {text-decoration: none; color:#FF6600;}
a.tj:link ,a.tj:visited {color: #FF0000;text-decoration: none;}
a.tj:hover { text-decoration: underline;color:#003278; }
a.tj:active {text-decoration: none; color:#003278;}
a.blue14:link ,a.blue14:visited {color: #001D4C;text-decoration: none; font-weight:bold; font-size:14px}
a.blue14:hover { text-decoration: none;color:#FF6600; font-weight:bold; font-size:14px }
a.blue14:active {text-decoration: none; color:#001D4C; font-weight:bold; font-size:14px}
.img {border:1px solid #cccccc;}
.zt_table {border:1px solid #DDDBDB;}
.zt_title { color:#FF6600; font-weight:bold; font-size:14px;}
.blut_title { color:#003278; font-weight:bold; font-size:14px;}
.blut12_unlink { color:#003399; font-weight:bold; }
.blue {color:#003278;}
.yellow12 {color:#FF3300;}
.yellow14{color:#FF3300; font-size:14px;}
.end_title {font-size:24px; font-family:"黑体"; color:#003278;}
.end_zw {font-size:14px; line-height:24px;}
.z666_unlink {color:#666666;}
.wywg_nolink {color: #FF6600;font-weight:bold; font-size:14px;}
a.wywg:link ,a.wywg:visited {color: #FF6600;text-decoration: underline; font-weight:bold; font-size:14px;}
a.wywg:hover { text-decoration: underline;color:#FF7F12; font-weight:bold; font-size:14px; }
a.wywg:active {text-decoration: underline; color:#FF6600; font-weight:bold; font-size:14px;}
a.zc:link ,a.zc:visited {color: #FF6600;text-decoration: underline; }
a.zc:hover { text-decoration: underline;color:#FF7F12; }
a.zc:active {text-decoration: underline; color:#FF6600; }
.d_default{
padding:2px 0 2px 4px;
border:1px solid #f7f7f7 ;
}
.d_on{
padding:2px 0 2px 4px;
border:1px solid #FFCC00;
color:#000;
background-color:#FFFFDD;
}
.d_ok{
padding:2px 0 2px 24px;
border:1px solid #00BE00;
color:#000;
background:#E6FFE6 url(li_ok.gif) no-repeat 4px;
}
.d_err{
border:1px solid #F30;
color:#F00;
padding:2px 0 2px 24px;
background:#FFF1E4 url(li_err.gif) no-repeat 4px;
}
========================
checkuser.asp:
===========================
<%
Response.ContentType &#61; "text/html"
Response.Charset &#61; "gb2312"
ys_name&#61;trim(request("username"))
set rs&#61;server.createobject("adodb.recordset")
sql&#61;"select ys_name,id from ys_imember where ys_name&#61;&#39;"&ys_name&"&#39;"
rs.open sql,conn,1,1
if rs.bof and rs.eof then
response.write "1"
else
response.write "0"
end if
rs.close
set rs&#61;nothing
%>
saveuser.asp:
<%ys_name&#61;request("username")
ys_pass&#61;request("password")
ys_email&#61;request("email")
set jrs&#61;server.CreateObject("adodb.recordset")
jsql&#61;"select ys_name,id from ys_imember where ys_name&#61;&#39;"&ys_name&"&#39;"
jrs.open jsql,conn,1,1
if jrs.eof and jrs.bof then
set rs&#61;server.CreateObject("adodb.recordset")
sql&#61;"select * from ys_imember where id is null"
rs.open sql,conn,1,3
rs.addnew
rs("ys_name")&#61;ys_name
rs("ys_pass")&#61;ys_pass
rs("ys_email")&#61;ys_email
rs.update
Session("ys_userame")&#61;ys_name
rs.close
set rs&#61;nothing
response.write "1"
else
response.write "0"
end if
jrs.close
set jrs&#61;nothing
%>
http://www.corange.cn/archives/2008/03/456.html