gg.asp

来自「网络书生留言本单用户 v1.0 正式版源码,大家下了就知道怎么用了!」· ASP 代码 · 共 58 行

ASP
58
字号
<!--#include file="Gbconn.asp" -->
<!--#include file="eof.asp" -->
<%
If request.Cookies("qzenetgbuser")="" then
response.Redirect("guestbook.asp")
Else
if request.QueryString("gg")="saves" then
Call saves()
else
Call gg()
end if

Sub gg()
%>
<SCRIPT language=javascript id=QzeNet>
<!--
function gg_onsubmit() 
{
    if(document.gg.u_news.value.length>100)
 {
   alert("写太多了,不要超过100字哦!");
   document.gg.u_news.focus();
   return false;
 }	
}
//-->
</SCRIPT>
<table width="600" border="0" align="center" cellpadding="0" cellspacing="0" class="tableg1">
  <tr>
    <td height="25" align="center">公告管理</td>
  </tr>
</table>
<table width="600" border="0" align="center" cellpadding="0" cellspacing="0" class="tableg2">
  <Form language=javascript name="gg" method="post" action="?gg=saves" onsubmit="return gg_onsubmit()">
  <tr> 
      <td height="70" align="center"> 
        <textarea name="u_news" cols="60" rows="3" id="u_news"><%=u_news%></textarea>
      </td>
  </tr>
  <tr>
      <td height="50" align="center"> 
        <input type="submit" name="Submit2" value="写好了" style="height:20px">&nbsp;&nbsp;
      <input type="reset" name="Submit3" value="重新写" style="height:20px">
      </td>
  </tr></form>
</table>
<%
end sub
sub saves()
dim u_news
u_news=request.Form("u_news")
conn.execute("update [user] set u_news='"&u_news&"'")
conn.close
response.Redirect("gg.asp")
end sub
End if
%>
<!--#include file="bof.asp" -->

⌨️ 快捷键说明

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