changeuserinfo.asp

来自「Activity——活动管理模块 Analyse——分析模块 Client—」· ASP 代码 · 共 52 行

ASP
52
字号
<%

%>
<!--#include file='../conn.asp'-->
<%
	For Each item in request.form		'对所有表单元素进行遍历
		if Left(item, 4) = "Pass" then	'如果表单名前四个字符是"Pass",说明该表单项为用户密码
			conn.execute("update [User] Set UserPass='"&request(item)&"' where UserID="&Cint(mid(item,5)))	'将数据添加到数据库,从表单名第5位开始为用户标识ID(UserID)
		end if
		if Left(item, 9) = "S_Section" then  '如果表单名前9个字符是"S_Section",说明该表单项为用户密码
			conn.execute("update [User] Set UserSection="&Cint(request(item))&" where UserID="&Cint(mid(item,10)))'将数据添加到数据库,从表单名第10位开始为用户标识ID(UserID)
		end if
		if Left(item, 7) = "IsAdmin" then	'如果表单名前7个字符是"IsAdmin",说明该表单项为用户密码
			conn.execute("update [User] Set IsAdmin="&Cint(request(item))&" where UserID="&Cint(mid(item,8)))'将数据添加到数据库,从表单名第8位开始为用户标识ID(UserID)
		end if
	Next
%>
	<html>
	<head>
	<title>更新用户记录</title>
	<meta http-equiv="Content-Type" content="text/html; charset=gb2312"><META HTTP-EQUIV="Pragma" CONTENT="no-cache">
	<LINK 
	href="../css.css" type=text/css rel=stylesheet>
	</head>

	<body>

	<br>
	<table width="100%" border="0" cellspacing="0" cellpadding="0" align=center>
	  <tr>
		<td width="100%" height="197" align="center">
	<table border="0" cellspacing="0" cellpadding="0" height="85" bgcolor="#99ccff" width="100%">
	<tr>
	<td align="center">
	<a href="UserInfoManage.asp" class=linkblue2>已更新用户记录</a>
	
		 <script>
			setTimeout("location.replace('UserInfoManage.asp')",2000)
		</script>


	</td>
	</tr>
	</table>
	</td>
	</tr>
	</table>
	<p>

	</body>
	</html>

⌨️ 快捷键说明

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