我的源代码是: ============================================= <!--#include file="conn.inc"--> <html>
<head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>笑红尘</title> </head>
<body bgcolor="#ffffff"> <% If Request("UID")<>"" AND Request("PWD")<>"" Then sql="SELECT * FROM current_user WHERE UID='" & Request("UID") & "'" Set current_userRs=conn.Execute(sql) If current_userRs.Bof or current_userRs.Eof Then '当前用户集中没有此人 LogTime=Now() SerialNum=Cstr(Hour(LogTime)) & Cstr(Minute(LogTime)) & Cstr(Second(LogTime))& Cstr(Int(Rnd*10000)) sql="INSERT INTO current_user (UID,Email,LastLogon,IPAddress,SerialNum) VALUES ('" sql=sql & Request("UID") & "','" & Request("Email") & "','" & Now() & "','" & Request("REMOTE_ADDR") & "','" & SerialNum & "')" conn.Execute (sql) Else SerialNum=current_userRs("SerialNum") End If current_userRs.Close Set current_userRs=Nothing End If '以上处理当前用户集,无论是登陆还是注册新用户,都要执行。
LogonSytle=Request("LogonSytle") If LogonSytle="登录" Then sql="SELECT * FROM ever_user WHERE UID='" & Request("UID") & "'" Set LogUserRs=conn.Execute(sql) If LogUserRs.Bof OR LogUserRs.Eof Then Response.Write "请检查是否输错,登陆失败。<br>" Else If Request("PWD")<>LogUserRs("PWD") Then Response.Write "口令出错,请检查是否大小写不对。<br>" Else Response.Redirect "main.asp?SerialNum=" & SerialNum End If End If ElseIf LogonSytle="新用户注册" OR LogonSytle="完成" Then sql="SELECT * FROM ever_user WHERE UID='" & Request("UID") & "'" Set LogUserRs=conn.Execute(sql) If Not (LogUserRs.Eof AND LogUserRs.Bof ) Then Response.Write "这个用户名已经被注册了,请选用其他的用户名。<br>" Else If LogonSytle="完成" Then sql="INSERT INTO ever_user (UID,PWD,Email,HomePage) VALUES ('" sql=sql & Request("UID") & "','" & Request("PWD") & "','" & Request("Email") & "','" & Request("HomePage") & "')" conn.Execute (sql) sql="UPDATE current_user SET Email='" & Request("Email") & "' WHERE UID='" & Request("UID") & "'" conn.Execute (sql) Response.Redirect "main.asp?SerialNum=" & SerialNum End If End If End If '程序处理完成,下面根据情况输出
%>
<form method="POST" action="default.asp"> <% If LogonSytle="" OR LogonSytle="登录" OR LogonSytle="完成" Then %> <div align="center"><center><p><font face="华文楷体"><big><big><font color="#FF0080">如果您是第一次进入本论坛,请选择新用户注册!</font></big></big><br> </font> </p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>你的姓名:</big></big></font><input type=text name=UID size=20 value="<% =Request("UID") %>" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"> <br> <font color="#FF0080" face="华文楷体"><big><big>你的口令:</big></big></font><input type="password" name="PWD" size="20" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"></p> </center></div><div align="center"><center><p><input type="submit" value="登录" name="LogonSytle"> <input type="submit" value="新用户注册" name="LogonSytle"> <% Else %> </p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>欢迎你来到这里,你可以在这里展现你的风采!</big></big></font></p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>你的姓名:</big></big></font><input type="text" name="UID" value=<% =Request("UID") %> size="20" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"> </p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>你的密码:</big></big></font><input type="text" name="PWD" value="<% request("PWD") %>" size="20" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"> </p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>电子邮件:</big></big></font><input type="text" name="Email" size="20" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"></p> </center></div><div align="center"><center><p><font color="#FF0080" face="华文楷体"><big><big>个人主页:<input type="text" name="HomePage" size="20" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"></big></big></font></p> </center></div><div align="center"><center><p><input type="submit" value="完成" name="LogonSytle"> <% End If%> </p> </center></div> </form> </body> </html> ============================================= 我的源代码写错了什么地方?见http://www.xnasp.net/home/pyzheng/(这个地方也可以看见源代码啊?) 才项下面的这个页面显示如图: 就是怎么不能在页面上隐藏掉不应该出现的代码?
比如:<font color="#FF0080" face="华文楷体"><big><big>你的姓名:</big></big></font><input type=text name=UID size=20 value="<% =Request("UID") %>" style="background-color: rgb(192,192,192); color: rgb(128,0,0)"> 有问题?有什么问题?value="<% =Request("UID") %>" 有什么问题?