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

📄 pic.asp

📁 夏茂政府网站
💻 ASP
字号:
<!--#include file="head.asp" -->
<%
    sub navigation()
    response.write " &gt;&gt; "
    response.write "图片展示"
    end sub
%>
<div align="left">
	<table border="0" cellpadding="0" cellspacing="0" width="996" height="50" bgcolor="#EFEFE7">
		<tr>
		<!--左边-->
			<td width="216" valign="top" background="images/2/left_bg.gif">
			
			<div align="center">
			<%call zf11_tianqi()%>
			</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_pic.gif" width="206" height="30" alt=""></TD>
			  </TR>
              <TR>
                <TD align=middle height=150><% Call zf11_pictype(15) %></TD>
			  </TR>
			  </TBODY>
			</TABLE>
           </div>
	   <div align="center">
			<% call zf11_Search5() %>
           </div>	   
           <div align="center">
			<% call zf11_login5()%>
           </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 zf11_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/class_top2.gif" width=780></TD>
					</tr>
				</table>


				<table border="0" cellpadding="0" cellspacing="0" width="780" height="31" background="images/pic_daohang_Bg.gif">
					<tr>
              <td style='FILTER: DropShadow(Color=#ffffff, OffX=1, OffY=1, Positive=1); PADDING-TOP: 2px'>&nbsp;&nbsp;<span style="letter-spacing: 3px">首页 &gt;&gt; <a href='pic.asp'>全部景点</a> 
<% if request.querystring("piccat_id")<>"" then
sql="select * from zf11_pic where piccat_id="&request.querystring("piccat_id")&" order by piccat_id desc"
    set rs1=conn.execute(sql)
    Response.Write "&gt;&gt; <a href=""pic.asp?piccat_id="&rs1("piccat_id")&""">"&rs1("piccat_name")&"</a>" 
    rs1.close 
end if
%>

             </span></td>
					</tr>
				</table>




	<table border="0" cellpadding="0" cellspacing="0" width="780" height="160" style="border: 0px solid #CECFCE">
		<tr>
			<td bgcolor="#FFFFFF" width="780">   
<!--主要内容开始-->

<%
dim founderr
founderr=false
if request.querystring("piccat_id")<>"" then
  if not isInteger(request.querystring("piccat_id")) then
    founderr=true
    Response.Write "<script language=javascript>alert('参数非法');javascript:history.back();</script>"
  end if
end if
if request("page")<>"" then
  if not isInteger(request("page")) then
    founderr=true
    Response.Write "<script language=javascript>alert('参数非法');javascript:history.back();</script>"
  end if
end if
if request("keyword")<>"" then
  if instr(request("keyword"),"'")>0 then
    founderr=true
    Response.Write "<script language=javascript>alert('搜索参数非法');javascript:history.back();</script>"
  end if
end if





dim totalpic,Currentpage,totalpages,i
sql="select id,pic_name,pic_spic,pic_count,pic_url,pic_date,pic_desc from zf11_p_news order by id DESC"
if request.querystring("piccat_id")<>"" then
sql="select id,pic_name,pic_spic,pic_count,pic_url,pic_date,pic_desc from zf11_p_news where piccat_id="&request.querystring("piccat_id")&" order by id DESC"
elseif request("keyword")<>"" then
sql="select id,pic_name,pic_spic,pic_count,pic_url,pic_date,pic_desc from zf11_p_news where "&request("select")&" like '%"&request("keyword")&"%'order by id DESC"
end if

set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
totalcs=rs.recordcount
%>&nbsp;

<TABLE id=middle cellSpacing=0 cellPadding=0 align=center boder="0">
  <TBODY>
  <TR vAlign=top align=center>
    <TD>
<table width="100%" border="1" align="center" cellspacing="0" cellpadding="3" bgcolor="#FFFFFF" bordercolor="#f0f0f0" style="border-collapse: collapse"><tr bgcolor="#FFFFFF">
      <%
dim picperpage
picperpage = 12
if not rs.eof then
rs.movefirst
rs.pagesize=picperpage
if trim(request("page"))<>"" then
   currentpage=clng(request("page"))
   if currentpage>rs.pagecount then
      currentpage=rs.pagecount
   end if
else
   currentpage=1
end if
   if currentpage<>1 then
       if (currentpage-1)*picperpage<totalcs then
	       rs.move(currentpage-1)*picperpage
		   dim bookmark
		   bookmark=rs.bookmark
	   end if
   end if
   if (totalcs mod picperpage)=0 then
      totalpages=totalcs\picperpage
   else
      totalpages=totalcs\picperpage+1
   end if
i=0
do while not rs.eof and i<picperpage

%>
<TD style="PADDING-RIGHT: 5px; PADDING-LEFT: 5px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px" align=middle><SCRIPT type=text/javascript>zf11Pic("<%=rs("pic_spic")%>","picnews.asp?id=<%=rs("id")%>","图片名称:<%=rs("pic_name")%>&#13&#10点击次数:<%=rs("pic_count")%>&#13&#10文件大小:<%=rs("pic_url")%>&#13&#10上传时间:<%=rs("pic_date")%>","<%=rs("pic_name")%>");</SCRIPT></TD>
<%
i=i+1
if i mod 4 = 0 then%>
</tr><tr bgcolor="#FFFFFF">
<%
end if
rs.movenext
loop
else
if rs.eof and rs.bof then
%>
<td align=middle height="60" colSpan=3><%if request("piccat_id")<> "" then%>该分类暂时没有图片<%elseif request("keyword")<>"" then%>没有找到包含[<b><font color=red><%=request("keyword")%></font></b>]的图片!<%else%>没有任何图片,请管理员到后台添加!<%end if%></td>
<%end if
end if%>
</tr><tr bgcolor="#ffffff"><td height="10" colspan="3"></td></tr><tr bgcolor="#FFFFFF"><TD colspan="3">

<TABLE align=center border=0>
<form name="form1" method="post" action="pic.asp?select=<%=request("select")%>&keyword=<%=request("keyword")%>&piccat_id=<%=request.querystring("piccat_id")%>">
<TR> 
<TD align=middle width="37%" height=25> 共[<font color="#FF6666"><%=totalcs%></font>]个作品 分[<font color="#FF6666"><%=totalpages%></font>]页</TD>
<TD width="40%" align=middle>
<%
if CurrentPage<2 then
response.write "<font color='999966'>首页 上一页</font> "
else
response.write "<a href=pic.asp?select="&request("select")&"&keyword="&request("keyword")&"&page=1&piccat_id="&request.querystring("piccat_id")&">首页</a> "
response.write "<a href=pic.asp?select="&request("select")&"&keyword="&request("keyword")&"&page="&CurrentPage-1&"&piccat_id="&request.querystring("piccat_id")&">上一页</a> "
end if
if totalpages-currentpage<1 then
response.write "<font color='999966'>下一页 尾页</font>"
else
response.write "<a href=pic.asp?select="&request("select")&"&keyword="&request("keyword")&"&page="&CurrentPage+1&"&piccat_id="&request.querystring("piccat_id")
response.write ">下一页</a> <a href=pic.asp?select="&request("select")&"&keyword="&request("keyword")&"&page="&totalpages&"&piccat_id="&request.querystring("piccat_id")&">尾页</a>"
end if
%>
</TD>
<TD align=middle width="23%">
<select name="page">
<%
i=1
for i=1 to totalpages
if i=currentpage then
%>
<option value=<%=i%> selected>第<%=i%>页</option> 
<%else%>
<option value=<%=i%>>第<%=i%>页</option> 
<%end if
next%>
</select><input type="submit" name="Submit2" value="转 向"> </TD>
</TR>
</FORM>
</TABLE>          
</TD>
</TR>
<tr align="center"><td height="1" colspan="3"></td></tr></table><br>
 
    </td>
</TBODY></TABLE>
<%
rs.close
set rs=nothing
%>

	
<!--主要内容结束-->
			</td>

		</tr>
	</table>
</td>
				<!--网站右边-->

</tr></table>
</div>


<!--#include file="foot.asp" -->

⌨️ 快捷键说明

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