📄 pic_body.asp
字号:
<%sub pic_body()%>
<TABLE bgcolor="#ffffff" align=center border=1 cellPadding=0 cellSpacing=0 width=760 borderColor="<%=border%>" frame=vsides rules=none>
<TBODY>
<TR>
<td height="116" width="756" valign="top" background="img/index_photo.jpg"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="756" height="114">
<param name=movie value="img/logo/top2.swf">
<param name=quality value=high>
<embed src="img/logo/top2.swf" quality=high pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="756" height="114">
</embed>
<param name="wmode" value="transparent">
</object></TD>
</TR>
<TR>
<td height="37" valign="top" align="right">
<%sql="select * from piccat"
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
do while not rs.eof
if request.querystring("piccat_id")<>Cstr(rs("piccat_id")) then%>
<img src=img/none.gif border=0><img src=img/link2.gif border='0'> <a href="pic.asp?piccat_id=<%=rs("piccat_id")%>"><%=rs("piccat_name")%></a>
<%else%>
<img src=img/none.gif border=0><img src=img/link2.gif border='0'> <font color="#ff6600"><%=rs("piccat_name")%></font>
<%end if
rs.movenext
loop
if rs.eof and rs.bof then%>
当前还没有图片分类
<%end if
dim totalpic,Currentpage,totalpages,i
sql="select * from pic order by pic_id DESC"
if request.querystring("piccat_id")<>"" then
sql="select * from pic where piccat_id="&request.querystring("piccat_id")&" order by pic_id DESC"
end if
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
totalcs=rs.recordcount%>
</TD>
</TR>
</TBODY>
</TABLE>
<TABLE align=center border=1 cellPadding=0 cellSpacing=0 width=760 borderColor="<%=border%>" frame=vsides rules=none>
<TBODY>
<TR>
<td width=553 align=left vAlign=top bgcolor="#ffffff"><%call br%>
<table width='530' height="25" border='0' align="center" cellpadding='3' cellspacing='0' background="img/mainbg.gif">
<tr>
<td> <img src="img/biao.gif" align="absmiddle"> 当前共有<span><%=totalcs%></span>个图片</td>
</tr>
</table>
<table width="530" border="0" cellpadding="1" cellspacing="0" align="center">
<tr>
<%
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 align="center" valign="middle">
<table width="144" height="109" border="0" cellpadding="0" cellspacing="0">
<TR><TD height=5></TD></TR>
<tr>
<td width="160" align="center">
<table width="160" height="130" border="0" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td bgcolor="#FFFFFF">
<table width="140" height="105" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#000000">
<tr>
<td><a href="javascript:openwin('repic.asp?pic_id=<%=rs("pic_id")%>')">
<img src="<%=rs("pic_pic")%>" border="0" width="140" height="105" border="0" title="图片名称:<%=rs("pic_name")%><br>点击次数:<%=rs("pic_count")%>次"></a></td>
</tr>
</table></td>
</tr>
</table></td>
<td width="17" align="center" valign="bottom"><img src="img/cool.gif" width="17" height="112" border="0"></td>
<TR><TD height=5></TD></TR>
</tr>
</table>
</td>
<%
i=i+1
if i mod 3 = 0 then%>
</tr><tr>
<%
end if
rs.movenext
loop
else
if rs.eof and rs.bof then
%>
<td align="center" valign="middle"> <table width="530" border="0" cellspacing="0" cellpadding="10" align="center">
<tr>
<td bgcolor="#FFFFFF" colspan="2" height="22" align="center">当前没有图片!</td>
</tr>
</table></td>
<%end if%></table>
<%end if
if not request("type")=1 then%>
<form name="form1" method="post" action="pic.asp?cscat_id=<%=request.querystring("piccat_id")%>">
<TABLE cellSpacing=1 cellPadding=0 width="530" align=center border=0 bgcolor="#999999">
<TBODY>
<TR>
<TD align=middle width="35%" height=25 bgcolor="#e6e6e6"><IMG height=14 src="img/cha.gif" width=14 align=absMiddle> 共[<font color="#FF6666"><%=totalcs%></font>]个作品 分[<font color="#FF6666"><%=totalpages%></font>]页</TD>
<TD width="40%" align=middle bgcolor="#e6e6e6"><IMG height=11 src="img/lt.gif" width=11 align=absMiddle>
<%
if CurrentPage<2 then
response.write "<font color='999966'>首页 上一页</font> "
else
response.write "<a href=pic.asp?page=1&piccat_id="&request.querystring("piccat_id")&">首页</a> "
response.write "<a href=pic.asp?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?page="&CurrentPage+1&"&piccat_id="&request.querystring("piccat_id")
response.write ">下一页</a> <a href=pic.asp?page="&totalpages&"&piccat_id="&request.querystring("piccat_id")&">尾页</a>"
end if
%>
<IMG height=11 src="img/gt.gif" width=11 align=absMiddle></TD>
<TD align=middle width="25%" bgcolor="#e6e6e6">
<select name="page" class="lanyu">
<%
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="轉向" class="button"> </TD>
</TR>
</FORM>
</TABLE>
<%end if%>
<%call br%><%call br%>
</td>
</TD>
<td width=1 height="190" background="img/xu.gif"></TD>
<td width=204 align=left vAlign=top background=img/left_bg2.gif>
<TABLE width=100% border=0 align=center cellPadding=0 cellSpacing=0>
<TBODY>
<TR><td width=204><img src=img/left_top2.gif usemap="#Map" border="0"><map name="Map"><area shape="rect" coords="61,11,87,24" href="book.asp?page=1" title="留言本"><area shape="rect" coords="134,11,160,24" href="admin.asp" title="后台管理"></map></td></tr>
</table>
<TABLE width=196 border=0 align=right cellPadding=0 cellSpacing=0>
<TBODY>
<TR>
<td align=center height="61"><img src="img/two/top.jpg" width="197" height="91"></td>
</tr>
<tr><td align="left"><%call br%>
<%sql="SELECT top "&toppicnum&" * FROM pic ORDER by pic_count DESC"
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
do while not rs.eof
%> <img src=img/none.gif border=0><img src=img/i6.gif border='0'> <a href="javascript:openwin('repic.asp?pic_id=<%=rs("pic_id")%>')" title="点击次数:<%=rs("pic_count")%>次"><%=rs("pic_name")%></a><br>
<%rs.movenext
loop
if rs.eof and rs.bof then%>当前还没有图片<%end if%><%call br%></td></tr>
<TR>
<td align=center height="61"><img src="img/two/tuijian.jpg" width="197" height="91"></td>
</tr>
<tr><td align="center"><%call br%>
<%sql="SELECT top "&bestpic&" * FROM pic where isbest = 1 ORDER by pic_date DESC"
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
do while not rs.eof
%><table width="144" height="109" border="0" cellpadding="0" cellspacing="0">
<TR><TD height=5></TD></TR>
<tr>
<td width="160" align="center">
<table width="160" height="130" border="0" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td bgcolor="#FFFFFF">
<table width="140" height="105" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#000000">
<tr>
<td><a href="javascript:openwin('repic.asp?pic_id=<%=rs("pic_id")%>')">
<img src="<%=rs("pic_pic")%>" border="0" width="140" height="105" border="0" title="图片名称:<%=rs("pic_name")%><br>点击次数:<%=rs("pic_count")%>次"></a></td>
</tr>
</table></td>
</tr>
</table></td>
<td width="17" align="center" valign="bottom"><img src="img/cool.gif" width="17" height="112" border="0"></td>
<TR><TD height=5></TD></TR>
</tr>
</table><%call br%>
<%rs.movenext
loop
if rs.eof and rs.bof then%>当前还没有图片<%end if%>
</td></tr>
</table>
</td>
</tr>
</table>
<%
rs.close
set rs=nothing
end sub%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -