📄 newuserlogin.asp
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="opendb.asp"-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<body>
<%
username=trim(request.Form("username"))
pwd=trim(request.Form("password"))
strsql="select * from userInf where UserName="&"'"&username&"'"
rst.cursortype=3
rst.open strsql
if rst.recordcount>0 then
%>
<script language="vbscript">
msgbox"该用户名已被使用,请重新键入",48,"注册失败"
window.history.go(-1)
</script>
<%else
rst.addnew
rst("UserName")=username
rst("password")=pwd
rst.update
rst.close
set rst=nothing
session("UserName")=username
%>
<script language="vbscript">
msgbox"用户注册成功,欢迎进入论坛",48,"注册成功"
window.location="index.asp"
</script>
<%end if%>
<!--#include file="closedb.asp"-->
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -