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

📄 readd.asp

📁 这是一个关于留言本的ASP程序设计,本人也是在网上找的,在这里提供大家学习用!
💻 ASP
字号:
<!--#INCLUDE FILE="odbc_connection.asp"-->
<!--#INCLUDE FILE="function.asp"-->
<HTML>
	<head>
		<title>我的留言板</title>
		<link rel="stylesheet" href="guest.css">
		<script language="JAVASCRIPT">
		<!--
		function Trim(str){
		  while (str !="" && str.charAt(0) == " ") str = str.substring(1,str.length);
		  while (str !="" && str.charAt(str.length-1) == " ") str = str.substring(0,str.length-1);
		  return str;
		}
		function check_Null(){
			if (Trim(document.form1.reback.value)==""){
				alert("回复不能为空!");
				return false;
			}
			if (Trim(document.form1.password.value)==""){
				alert("密码不能为空!");
				return false;
			}
			return true;
		}
		// -->
		</script>
	</head>
<body >
<%
dim guest_id
guest_id=request("id")

%>
	<center><h1>回复</h1></center>
	<center>
		<table border='1' width='80%' cellspacing='0' bordercolorlight='#000000' bordercolordark='#FFFFFF'  cellpadding='0' height="114">
		<tr bgcolor=#203F80>
		<td>

	<TABLE border="0" width=100%>
		<form METHOD="POST" ACTION="" name="form1" onsubmit="javascript: return check_Null();">
			<tr><td><font color=white>主题:</font></td><td><font color=white>re:<%=request("title")%></font></td></tr>
			<tr><td><font color=white>内容:</font></td><td><Textarea Name="reback" Rows=4 Cols=60 WRAP=SOFT></TextArea></td></tr>
			<tr><td><font color=white>回复密码:</font></td><td><input type="password" name="password" size="10" value=""><font color=white>必须输入密码,才能回复。</font></td></tr>
			<tr><td></td><td><input TYPE="submit" VALUE=" 提交 " Size="20"></td></tr>
		</form>
	</table>
	</td>
	</tr>
	</table>
	
	<p align="center">(注:仅供本人回复)
	</CENTER>

	<%
	if request("reback")<>"" then
	    if request("password")<>password then
			response.write "对不起,必须输入正确的回复密码"
		    response.end 
		end if
		sql="update guest set reback='" & myReplace(request("reback")) & "' where guest_id=" & guest_id 
		db.execute(sql)
		response.redirect("index.asp")
	end if
	%>
</body>
</HTML>

⌨️ 快捷键说明

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