<!--#include file="inc_top.asp" -->
<table width="762" bgcolor=#f7f7f7 align="center" cellpadding="0" cellspacing="0" class="table-zuoyou">
<tr><td width=760 height=40 align=center><a href="alltop.asp">【 全部头条推荐 】</a>  <a href="alltop.asp?lbid=0">【 首页头条推荐 】</a></td></tr>
<tr><td width=760>
<table width="720" align="center" cellpadding="0" cellspacing="0">
<tr>
<% set rs = conn.execute("select * from lb order by lbid")
	j=0
	while not rs.eof%>
<TD height=24 width=144><font color=#ff3300>＋</font>&nbsp;<a href="?lbid=<%=rs("lbid")%>" target="_blank"><%=rs("lbname")%></a></td>
	<% rs.movenext
	j=j+1
	if j mod 5=0 then response.write "</tr><tr>"
	wend
	rs.close
	set rs=nothing %>
</tr>
</table>
</td></tr>
</table>
<table width="762" bgcolor="#efefef" align="center" cellpadding="0" cellspacing="1" class="table-zuoyou">
	<% 
	lbid=cint(Request("lbid"))
	if lbid="" or isempty("lbid") then
	set rs = conn.execute("select * from firstpic order by id desc")
	else
	set rs = conn.execute("select * from firstpic where lbid='"&lbid&"' order by id desc")
	end if
	if rs.eof then
		response.write "<tr><td align=center><font color=blue>本类别暂时没有头条推荐图片!</font></td></tr>"
		rs.close
		set rs=nothing
	else
		rs.pagesize = 6
		if request("page")=""  or isempty(request("page")) then
		page = 1
		else
		page=cint(request("page"))
		end if
		if page>rs.pagecount then
		page=rs.pagecount
		end if
		if not rs.BOF then
		Rs.Move Rs.PageSize*(page-1)
		end if
		i=1
%>
	<tr><td height=1 bgcolor=#cccccc></td><tr>
<%	do while not rs.eof and i<=rs.pagesize %>
	<tr height="30" valign="middle" bgcolor="#FFFBF7">
	<td align=center><font color=blue><%=rs("dates")%></font></td>
	</tr>
	<tr><td align=center><a href="<%=rs("link1")%>" target=_blank><img src="pic/<%=rs("pic1")%>" border=0></a><%if rs("pic2")<>"" then
response.write rs("ifbr1")&"<a href="&rs("link2")&" target=_blank><img src=pic/"&rs("pic2")&" border=0></a>"
end if
if rs("pic3")<>"" then
response.write rs("ifbr2")&"<a href="&rs("link3")&" target=_blank><img src=pic/"&rs("pic3")&" border=0></a>"
end if%></td>
	</tr>
<%
	rs.movenext
	i=i+1
	loop
%>
<tr><td height=1 colspan=3 bgcolor=#cccccc></td><tr>
<tr><td colspan=3>
  <table width="98%" height="30" align="center" cellpadding="0" cellspacing="0">
        <form name=form method=post action=?lbid=<%=cint(request("lbid"))%>>
          <tr> 
            <td valign="middle" align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <%
if rs.recordcount<>0 then
if page-1 mod 10=0 then
		p=(page-1) \ 10
	else
		p=(page-1) \ 10
	end if

	response.write " >> 分页："

	if p*10>0 then response.write "<a href='?lbid="&cint(request("lbid"))&"&page="&p*10&"' title=上十页>[&lt;&lt;]</a>   "
    uming_i=1
	for ii=p*10+1 to P*10+10
		   if ii=page then
	          response.write "<font color=#ff0000>["+Cstr(ii)+"]</font> "
		   else
		      response.write "<a href='?lbid="&cint(request("lbid"))&"&page="&ii&"'>["+Cstr(ii)+"]</a>   "
		   end if
		if ii=rs.pagecount then exit for
		 uming_i=uming_i+1
	next
	if ii<=rs.pagecount and uming_i=11 then response.write "<a href='?lbid="&cint(request("lbid"))&"&page="&ii&"' title=下十页>[&gt;&gt;]</a>   "
response.write(" 　跳页：<input type=text name=page size=2 maxlength=3 class=wenbenkuang> <input type=submit name=Submit2 value=Go class=go-wenbenkuang>")
end if
rs.close
set rs=nothing%> </td>
          </tr>
        </form>
      </table>
</td></tr>
<% end if%>
</table>
<!--#include file="inc_end.asp" -->