📄 guest.asp
字号:
<!--#include file="conn.asp"-->
<!--#include file="Config.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><%= cfgTitle %></title>
<style type="text/css">
<!--
body {
background-color: #666688;
}
-->
</style>
<style type="text/css">
<!--
.style3 {
font-size: 14px;
font-weight: bold;
color: #FFFFFF;
}
-->
</style>
<link href="Style.css" rel="stylesheet" type="text/css">
<%
if request("action") = "save" then
call creaters(rs,"select * from users where username='" & request("user") & "'")
if rs.eof then response.Redirect("Guest.asp?action=Err")
call closers(rs)
call creaters(rs,"select * from guest")
rs.addnew
rs("username") = request("user")
rs("GuestName") = request.Form("GuestName")
rs("Content") = request.Form("Content")
rs("date") = date()
rs.update
call closers(rs)
%>
<script language="javascript">
alert("恭喜您,留言成功!");
history.back(1);
</script>
<%
end if
%>
</head>
<body>
<!--#include file="top.asp"-->
<link href="Style.css" rel="stylesheet" type="text/css">
<table width="614" border="0" align="center" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="614" height="15" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="614" height="15"></td>
</tr>
</table></td>
</tr>
<tr>
<td height="29" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="614" height="29" valign="middle" background="images/Main_01.gif"> <span class="style3">给我留言</span></td>
</tr>
</table></td>
</tr>
<tr>
<td height="80" valign="top"><table width="100%" border="0" cellpadding="10" cellspacing="0" background="images/Main_02.gif">
<!--DWLayoutTable-->
<tr>
<td width="614" height="80" align="left" valign="top">
<table width="99%" height="89" border="0" align="center" cellpadding="5" cellspacing="1" bgcolor="#C0E096">
<form name="frmUnit" action="Guest.asp?user=<%= request("user") %>&action=save" method="post">
<tr>
<td height="21" colspan="2" bgcolor="#FFFFFF"><a href="#"><strong> 请输入留言内容</strong></a></td>
</tr>
<tr>
<td width="23%" height="21" bgcolor="#F3F9EC"><div align="right"><strong>您的大名:</strong></div></td>
<td width="77%" bgcolor="#F3F9EC"><input name="GuestName" type="text" class="InputBox" id="GuestName" size="50"></td>
</tr>
<tr>
<td height="21" bgcolor="#FFFFFF"><div align="right"><strong>内容:</strong></div></td>
<td height="21" bgcolor="#F3F9EC"><textarea name="Content" cols="50" rows="6" class="InputBox" id="Content"></textarea></td>
</tr>
<tr>
<td height="21" colspan="2" bgcolor="#F3F9EC"><div align="center">
<input name="btnSubmit" type="button" class="InputBox" id="btnSubmit" value="提交">
<input name="Submit2" type="reset" class="InputBox" value="重置">
</div></td>
</tr>
</form>
</table>
</td>
</tr>
</table></td>
</tr>
<tr>
<td height="25" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="614" height="25" valign="top"><img src="images/Main_03.gif" width="614" height="25"></td>
</tr>
</table></td>
</tr>
</table>
<!--#include file="down.asp"-->
</body>
</html>
<script language="vbscript">
sub btnSubmit_onclick()
if frmUnit.GuestName.value = "" then
msgbox "请输入您的大名",VbCritical,"您的大名"
exit sub
end if
if frmUnit.Content.value = "" then
msgbox "请输入留言内容",VbCritical,"留言内容"
exit sub
end if
frmUnit.submit
end sub
</script>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -