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

📄 leadingbox.asp

📁 政府网站集成OA办公考勤新闻发布网站信息管理会员管理
💻 ASP
📖 第 1 页 / 共 2 页
字号:
<!--#include file="head.asp" -->
<%
sub navigation()
response.write " &gt;&gt; "
response.write leader&"信箱--"&a125_title
end sub
%>
<table border="0" cellpadding="0" cellspacing="0" width="980" height="50" bgcolor="#ffffff">
	<tr>
 <!--左边内容-->
		<td width="216" valign="top" background="images/2/left_bg.gif">
		  <div align="center">
			<%call a125_tianqi()%>
			</div>
			<div align="center">
<% Call a125_acticletype(15,-4,"政民互动") %>              
      </div>
		  <div align="center">
			<% call a125_Search5() %>
      </div>
      <div align="center">
       <TABLE cellSpacing=0 cellPadding=0 width=212 border=0>
        <TBODY>
          <TR>
           <TD align=middle height=30><img src="images/2/index_80.gif" width="206" height="30" alt=""></TD>
			    </TR>
          <TR>
            <TD align=middle height=200><% Call a125_articleInfo(1,8,20,0,0) %></TD>
			   </TR>
			  </TBODY>
			 </TABLE>
      </div>
     </td>	
     <td width="780" valign="top">
			<table border="0" cellpadding="0" cellspacing="0" width="780" height="20" >
			 <tr>
        <TD width="100%" height="20" ><IMG height=45 src="images/2/liuyan_top.gif" width=780></TD>
			 </tr>
			</table>
			<table border="0" cellpadding="0" cellspacing="0" width="780" height="32" id="table1" background="images/2/liuyan1.gif">
	  		<tr>
					<td width="40"></td><td width="470"><%=leader%>信箱</td>
	        <td width="63" valign="bottom"><a href="<%=indexfilename%>?action=Add_New">
					<img border="0" src="images/a125_clarity4.gif" width="63" height="17"></a></td>
					<td width="51"></td>
					<td width="67" valign="bottom"><a href="<%=indexfilename%>?action=View_a125_gb">
					 <img border="0" src="images/a125_clarity4.gif" width="63" height="17"></a></td>
					<td width="89"></td>
					</tr>
			</table>
      <table border="0" cellpadding="0" cellspacing="0" width="780" height="160" style="border: 0px solid #CECFCE">
	      <tr>
			   <td bgcolor="#FFFFFF" width="100%"> 
           <!--信箱内容开始-->
          <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
           <TR> 
            <TD height=56>
<%
    dim indexfilename,indeximg,n,x,m
    indexfilename=right(Request.ServerVariables("PATH_TRANSLATED"),(len(Request.ServerVariables("PATH_TRANSLATED"))-instrRev(Request.ServerVariables("PATH_TRANSLATED"),"\"))) 
    imdeximg="Images/" '图片文件夹
    n=5 '每页显示邮件数
    x=5  '每页显示的页数
    txt=1000  '邮件的最大字数
           dim webtitle,webname,webyn,webgl,webyn2,view2
           set rs1 = conn.execute("select * From a125_Set")
           webtitle=rs1("title")
           if rs1("webname")<>"" then webname=rs1("webname")
           if rs1("gbyn")<>"" then webyn=rs1("gbyn")
           webgl=rs1("gl")
           rs1.close
           set rs1=nothing
    '设置页脚信息
    page =Request.QueryString("page")
    if page="" or page=0 then page=1
    action = Request.QueryString("action")
    action_e = Request.Form("action_e")
    if action_e <>"" then
    server_v1=Cstr(Request.ServerVariables("HTTP_REFERER")) 
    server_v2=Cstr(Request.ServerVariables("SERVER_NAME")) 
    if mid(server_v1,8,len(server_v2))<>server_v2 then 
    response.write "<br><br><center><table border=1 cellpadding=20 bordercolor=black bgcolor=#EEEEEE width=450>" 
    response.write "<tr><td style='font:9pt Verdana'>" 
    response.write "你提交的路径有误,禁止从站点外部提交数据!" 
    response.write "</td></tr></table></center>" 
    response.end 
    end if 
    end if
%>
<script language="JavaScript">
    function gbcount(message,total,used,remain)
    {
	var max;
	max = total.value;
	if (message.value.length > max) {
	message.value = message.value.substring(0,max);
	used.value = max;
	remain.value = 0;
	alert("邮件内容不能超过 <%=txt%> 个字!");
	}
	else {
	used.value = message.value.length;
	remain.value = max - used.value;
	}
    }
</script>
  <table width="760" height="18" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" >
    <tr>
      <td width="760" height="10" align="center" valign="top">
<%
    '主程序
    Select Case action_e
    Case "Add_New"
    Call Add_New_Execute()
    End Select
    Call Main_Menu()
    Select Case action
    Case ""
    Call View_a125_gb()
    Case "Add_New"
    Call Add_New()
    Case "View_a125_gb"
    Call View_a125_gb()		
    End Select
%>      </td>
    </tr>
  </table>
<% Sub Add_New() %>
<table width="760" border="0" align="center" cellpadding="4" cellspacing="1" bgcolor="#CCCCCC">
<form name="form" method="post" action="<%=indexfilename%>">
 <tr bgcolor="#FFFFFF"> 
  <td width="13%" height="20" align="right" >姓名:</td>
  <td width="53%" height="20"> <input type="text" name="name" class="write" size="20" maxLength=8>*8个字内</td>
<script>
    function showimage(){document.images.showimages.src="<%=imdeximg%>"+document.form.sex.options[document.form.sex.selectedIndex].value+""+document.form.img.options[document.form.img.selectedIndex].value+".gif";}
</script>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td height="20" align="right"> 性别: </td>
  <td height="20">
   <select name="sex" size="1" onChange="showimage()">
   <option value="1">男</option>
   <option value="0">女</option>
   </select> </td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td height="20" align="right">联系电话:</td>
  <td height="20"> <input name="phone" type="text" id="phone" size="35" maxLength=15 class="write"></td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td height="20" align="right">QQ:</td>
  <td height="20"> <input name="qq" type="text" id="qq" size="35" maxLength=15 class="write"></td>
 </tr>
  <input name="web" type="hidden" value="http://">
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td height="20" align="right">联系地址:</td>
  <td height="20"> <input name="come" type="text" id="come" size="35" class="write"></td>
 </tr>
 <tr bgcolor="#FFFFFF">
  <td height="20" align="right">电子邮箱:</td>
  <td height="20"><input name="email" type="text" value="" size="35" maxlength=25 class="write"></td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td height="20" align="right">主题:</td>
  <td height="20">
  <input name="title" type="text" class="write" id="title" size="35" maxLength=50>*</td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td align="right" valign="top"> 邮件内容: </td>
  <td> <textarea name="a125_gb" cols="50" rows="8" class="input1" id="a125_gb" 
	  onKeyDown=gbcount(this.form.a125_gb,this.form.total,this.form.used,this.form.remain); 
	  onKeyUp=gbcount(this.form.a125_gb,this.form.total,this.form.used,this.form.remain);></textarea>* </td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td align="right" valign="top" height="30"> </td>
  <td height="30">最多字数: <INPUT disabled maxLength=4 name=total size=3 value=<%=txt%>>已用字数:<INPUT disabled maxLength=4 name=used size=3 value=0>剩余字数:<INPUT disabled maxLength=4 name=remain size=3 value=<%=txt%>></td>
 </tr>
 <tr bgcolor="#FFFFFF"> 
  <td align="right" valign="top" height="30"> </td>
  <td height="30"> 您的联系方式及信件内容会被保密</td>
 </tr>
 <tr align="center" bgcolor="#EAEAEA"> 
  <td height="20" colspan="2"><input type="hidden" name="action_e" value="Add_New"> 
  <input type="submit" name="Submit" value=" 提 交 " class="input1"> <input type="reset" name="Submit2" value=" 重 写 " class="input1"></td>
 </tr>
 </form>
</table>
<br>
<% End Sub %>
<% Sub Main_Menu() %>
	<table border="0" cellpadding="0" cellspacing="0" width="100%" height="10">
		<tr>
			<td></td>
		</tr>
	</table>
<% End Sub 
    '查看邮件
    Sub View_a125_gb() 
         dim gbcount,y,j,k
         set rs = conn.execute("select COUNT(*) as gbcount From a125_gb where view>1")
		 gbcount=rs("gbcount")
		 rs.close
		 
		 if gbcount/n = int(gbcount/n) then '计算出分页数
		 y=int(gbcount/n)
		 else
		 y=int(gbcount/n)+1
		 end if

         page2= int(page/x)
		 if page/x>page2 then page2=page2+1
		 k=page2*x
		 if k>y then k=y

		 '打开邮件字段'
		 if page=1 then
		 sql="select top "&n&" id,name,sex,web,email,title,a125_gb,date,reply,ip,come,view,qq,phone From a125_gb where view>1 Order By id Desc"
		 else
		 sql="select id,name,sex,web,email,title,a125_gb,date,reply,ip,come,view,qq,phone From a125_gb where view>1 Order By id Desc"
		 end if
		 if Page >100 then
            rs.Open sql,Conn,1
         else
            Set Rs=Conn.Execute(sql)
         end if
         if Page>1 then RS.Move n*page-n
%>
<table width="560" border="0" cellspacing="0" cellpadding="0" align="center">
 <tr>      
  <td width="100%" height="20"></td>
 </tr>
</table>
<% if rs.bof and rs.eof then Response.Write "当前没有邮件记录" %>
<%
    dim lou,a125_gb,reply,email,qq,web,come,phone
    if Request.QueryString("page")<2 then
    lou=gbcount
    else
    lou=gbcount-((Request.QueryString("page")-1)*n)
    end if 
    i=0
    do while not rs.eof and i<n
    i=i+1
    reply=""
    a125_gb=""  
    a125_gb=rs("a125_gb")
    reply=rs("reply")
%>
<TABLE width="100%" height=10 border=0 align=center cellPadding=0 cellSpacing=1 style="border-collapse:collapse" >
  <TR >
    <TD colSpan=2 height=30><table width="100%" height="30"  border="0" background="images/a125_gbdaohang.gif" class="unnamed1">
  <tr>
   <td height="21">&nbsp;&nbsp;主题:<b><%=LeftStr(rs("title"),6)%>。。。。。。</b></td>
   <td> 
<img src="<%=imdeximg%>phone.gif" alt="联系地址:对外保密" width="16" height="16" border="0">
<img src="<%=imdeximg%>a125_email.gif" alt="联系地址:对外保密" width="16" height="16" border="0"></a> 
<img src="<%=imdeximg%>a125_oicq.gif" alt="联系地址:对外保密" width="16" height="16" border="0">
<img src="<%=imdeximg%>a125_come.gif" alt="联系地址:对外保密" width="16" height="16"> 对外保密
  </td>
  <td width="20%"> 第 <font color="#ff0000"><%=lou %></font> 条邮件</td>
 </tr>
</table>
</TD>
</TR>
<TR>
<TD width="111" height="21" align=middle valign="top"> 
<table width="100%" border="0" align="center">
 <tr>
  <td width="118"align="center">
<%if rs("sex")=1 then %>
  <img src="<%=imdeximg%>a125_male.gif">
<% else %>
  <img src="<%=imdeximg%>a125_female.gif">
<% end if %>
<br>
姓名保密</td>
 </tr>
</table>
</TD>       
<TD width="760" height="21"  style="word-break:break-all"> 
<table width="96%" height="132" border="0" align="center">
 <tr>
  <td width="100%" height="70" style="line-height: <%=a125_line_H%>"> 
<br>
<% if webyn=1 and rs("view")=3 then %>
<%=LeftStr(Ubb(unHtml(a125_gb)),12)%>。。。。。[具体内容对外保密]
<% if len(trim(reply))>1 then%>
  <hr size="1">
  <span class="style1">回复:</span><br>
  <font color="#990000"> <%=Ubb(unHtml(reply))%> </font>
<%end if %>
<%end if %>
<% if webyn<>1 then %>
<%=LeftStr(Ubb(unHtml(a125_gb)),12)%>。。。。。[具体内容对外保密]
<% if len(trim(reply))>1 then%>
  <hr size="1">
  <span class="style1">回复:</span><br>
  <font color="#990000">Ubb(unHtml(reply)) </font>
<%end if %>
<%end if %>
<% if webyn=1 and rs("view")=2 then%>
              正在对您的邮件进行审批... 
<%end if %></td>
 </tr>
 <tr>
  <td height="22" align="right" style="word-break:break-all">发表于:<%=year(Rs("date"))%>年<%=month(Rs("date"))%>月<%=day(Rs("date"))%>日</td>
 </tr>
</table></TD>
</TR>
</TABLE>
<%
    lou=lou-1	 
    rs.movenext
    loop
    Rs.Close
    Set Rs = Nothing
%>
<table width="570" border="0" cellspacing="1" cellpadding="4" align="center">
 <tr>    
  <td width="100%" height="20" align="center" class="unnamed1"> 有<%=gbcount %>条邮件 <%=page %>/<%=y %>页 分页 <a href="?page=1"><<</a>
<% if page2>1 then %>
  <a href="<%=indexfilename%>?page=<%=page2*x-x%>"><</a>
<% end if %>
<% For m =page2*x-(x-1) To k %>
[<a href="<%=indexfilename%>?page=<%=m%>"><%=m%></a>]
<% Next %>
<% if page2*x < y then %>
<a href="<%=indexfilename%>?page=<%=m%>">></a>

⌨️ 快捷键说明

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