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

📄 affiche_agent_add.asp

📁 视频点播系统
💻 ASP
字号:
<!--#include file="chklogin.asp"-->
<%

call myobj.chkrq()
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>发布新代理商公告</title>
<link href="images/style2.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
body,td,th {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	color: #000000;
}
a:link {
	color: #0000FF;
	text-decoration: none;
}
a:visited {
	color: #0000FF;
	text-decoration: none;
}
a:hover {
	color: #FF0000;
	text-decoration: underline;
}
a:active {
	text-decoration: none;
}
-->
</style></head>

<body leftMargin="0" topMargin="0" bgcolor="#FFFFFF">
<%
action_e=request.QueryString("action")
Select Case action_e
	Case ""
	  Call main()
	Case "save_affiche"
	  Call save_affiche()
end select
%>
<%
sub main()
%>
<form name="form1" method="post" action="<%=filename%>?action=save_affiche">
<table width="550" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>
<table width="550" height="25" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#3975CE">
  <tr>
    <td align="center" class="font1"><strong class="font1">发布新代理商公告</strong></td>
  </tr>
</table>

<table width="550" height="280" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#E7E7E7">
  <tr>
    <td align="center" bgcolor="#F7F7F7"><table width="500" height="25" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td width="100" align="right">代理商公告标题:</td>
        <td><input name="a_title" type="text" class="input1" id="a_title" size="51"></td>
      </tr>
    </table>
      <table width="500" height="25" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td width="100" align="right">代理商公告正文:</td>
          <td><textarea name="a_body" cols="50" rows="10" class="input1" id="a_body"></textarea></td>
        </tr>
      </table>
      <table width="500" height="25" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td width="100" align="right">是否置顶:</td>
          <td><input type="radio" name="on_top" value="true">
            是 
            <input name="on_top" type="radio" value="false" checked>
            否</td>
        </tr>
      </table>
      <table width="500" height="40" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td align="center"><input name="Submit" type="submit" class="button1" value="确定发布"> 
            <input name="Submit" type="reset" class="button1" value="清空重写"></td>
        </tr>
      </table></td>
  </tr>
</table>
</form>
<%end sub%>
<%
sub save_affiche()
if request.form("a_title")="" or myobj.ChkLen(request.form("a_title"))>50 then
response.write"<script language=javascript>alert('代理商公告标题不能为空,并且不能大于50个字符(汉字占两个字符)');history.back();</Script>"
response.end
end if
if request.form("a_body")="" or myobj.ChkLen(request.form("a_body"))>500 then
response.write"<script language=javascript>alert('代理商公告正文不能为空,并且不能大于500个字符(汉字占两个字符)');history.back();</Script>"
response.end
end if
if myobj.chkbool(request.form("on_top"))=false then
response.write"<script language=javascript>alert('代理商公告置顶属性值类型错误');history.back();</Script>"
response.end
end if
set rs=server.createobject("adodb.recordset")
rs.open "select * from affiche where (id is null)",conn,1,3
rs.addnew
rs("a_type")=2
rs("a_title")=request.form("a_title")
rs("a_body")=request.form("a_body")
rs("on_top")=cbool(request.form("on_top"))
rs.update
rs.close
set rs=nothing
conn.close
set conn=nothing
%>

<table width="550" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>
<table width="550" height="25" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#3975CE">
  <tr>
    <td align="center" class="font1"><strong class="font1">代理商公告发布成功</strong></td>
  </tr>
</table>
<table width="550" height="100" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#E7E7E7">
  <tr>
    <td align="center" bgcolor="#F7F7F7"><p>代理商公告发布成功!</p>
    <p><a href="<%=filename%>">继续发布新代理商公告</a> <a href="affiche_agent_manage.asp">管理已发布的代理商公告</a></p></td>
  </tr>
</table>
<%
end sub
%>
</body>
</html>

⌨️ 快捷键说明

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