<% if request("action")="login" then if request("username")="" then Response.Write "" response.end end if if request("password")="" then Response.Write "" response.end end if set rs=server.createobject("adodb.recordset") dengsql="select * from Hover_Users where UserName='"&request("username")&"' and Password='"&MD5(request("password"))&"'" rs.open dengsql,conn,1,3 if rs.recordcount<=0 then Response.Write "" response.end else session("username")=request("username") rs("LastLoginTime")=now rs("LoginIP")=request.ServerVariables("REMOTE_ADDR") rs("logins")=cint(rs("logins"))+1 rs.update end if rs.close set rs=nothing conn.close set conn=nothing response.write " " Response.end end if if request("action")="zhuche" then if request("username")="" then Response.Write "" response.end end if if request("password")="" then Response.Write "" response.end end if if len(request("password"))<6 then Response.Write "" response.end end if if request("password")<>request("repassword") then Response.Write "" response.end end if set rs=server.createobject("adodb.recordset") zhusql="select * from Hover_Users" rs.open zhusql,conn,1,3 rs.addnew rs("UserName")=request("username") rs("Password")=MD5(request("password")) rs("Phone")=request("teleph") rs("LastLoginTime")=now rs.update rs.close set rs=nothing conn.close set conn=nothing session("username")=request("username") response.write " " Response.end end if %> <% if isnull(session("username")) or session("username")="" then %> 登录 | 注册 <% else %> <%=session("username")%> ,欢迎您! <% end if %>