⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 member.asp

📁 数据库课程设计
💻 ASP
字号:
<%@ LANGUAGE="VBScript" %>
<script language="vbscript" src="details.vbs"></script>
<html>
<head><title>注册系统</title></head>
<body bgcolor="#FFFF99"><body background="img\backgd.jpg"></body>
<center>
<form name="freg" action="register.asp" method="post">
<%
' 注释:保存用户信息的相关变量赋初值——空值
   userid = "" : name = ""  : zip= ""   : address = ""
   tel = ""    : email = "" : note = ""
   msg = "<font size=5 face=楷体_GB2312><b>用户注册</b></font><hr>"
' 注释:分析需要执行的操作——有用户信息则显示用户注册资料
   If Session("userid") <> "" Then
      msg = "<font size=5 face=楷体_GB2312><b>会员资料</b></font><hr>"
   ' 注释:生成SQL查询语句
      mysql = "SELECT * FROM customer " & _
               "WHERE id = '" & Session("userid") & "'"
   ' 注释:连接数据库并执行SQL语句
   	Set objRS = Session("objRS")
      objRS.Source = mysql
      objRS.Open
   ' 注释:显示相关结果
      If objRS.RecordCount > 0 Then
         userid = objRS("id")
         name = objRS("name")
         zip = objRS("zipcode")
         address = objRS("address")
         tel = objRS("tel")
         email = objRS("email")
         note = objRS("note")
      Else
         msg = msg & "没有找到用户[" & Session("userid") & "]的相关信息!请稍后重试..."
      End If
   ' 注释:关闭数据记录集
      objRS.Close
      Set objRS = Nothing
   End If
   Response.Write(msg)
%>
<!-- 显示用户信息 -->
<table>
<tr><th align=right>会员名:</th><td>
   <input name=userid type=text size=30 maxlength=15 value=<% =userid %> 
   <% If userid <> "" Then %> readonly <% End If %>>
   <font color="red">*</font>
</td></tr>
<tr><th align=right>密码:</th><td>
   <input name=pass type=password size=30 maxlength=15>
   <font color="red">*</font>
</td></tr>
<tr><th align=right>重复密码:</th><td>
   <input name=repass type=password size=30 maxlength=15>
   <font color="red">*</font>
</td></tr>
<tr><th align=right>认证码:</th><td>
   <input name=affirm type=password size=30 maxlength=15>
</td></tr>
<tr><th align=right>真实姓名:</th><td>
   <input name=name type=text size=30 maxlength=20 value=<% =name %>>
</td></tr>
<tr><th align=right>邮编:</th><td>
   <input name=zip type=text size=30 maxlength=6 value=<% =zip %>>
</td></tr>
<tr><th align=right>地址:</th><td>
   <input name=address type=text size=30 maxlength=50 value=<% =address %>>
</td></tr>
<tr><th align=right>联系电话:</th><td>
   <input name=tel type=text size=30 maxlength=50 value=<% =tel %>>
</td></tr>
<tr><th align=right>E-Mail:</th><td>
   <input name=email type=text size=30 maxlength=50 value=<% =email %>>
</td></tr>
<tr><th align=right>备注:</th><td>
   <input name=note type=text size=30 maxlength=50 value=<% =note %>>
</td></tr>
<tr><td colspan=2><hr></td></tr>
<tr><th colspan=2>
   <input type="submit" value=' 提 交 '>&nbsp;
   <input type="reset" value=' 重 填 '>
</th></tr>
</table><hr>
<a href="#" onClick="vbscript:window.close" 
   onmousemove="window.status='关闭窗口'"
   onmouseout ="window.status=''">关闭窗口
</a>
</form>
</center>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -