www.gusucode.com > 漂亮的地方旅游景点景观介绍网站源代码 > newsclass.asp

    <!--#include file="config.asp" --><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML><HEAD>
<%
if fid=0 then 
fid=1
end if

dim dh
dh="<a href=""index.asp"">首页</a> &gt;&gt; "&getdaoh2("jw_newsclass")&"&gt;&gt; 文章列表"
mytit=getmc("jw_newsclass","id",fid,"mc")
call headinfo()

select case fid
case 3
ym=5
case 4
ym=6
case 5
ym=7
case 6
ym=8
case 9
ym=13
case 13
ym=11
case 11
ym=12
case 12
ym=10
case 10
ym=14
end select

%>
<LINK href="skins/css/web.css" type=text/css 
rel=stylesheet><LINK href="skins/css/zhinan_index.css" type=text/css 
rel=stylesheet>
<LINK media=all href="skins/css/gb_styles.css" type=text/css rel=stylesheet>
<META content="MSHTML 6.00.2900.3268" name=GENERATOR></HEAD>
<BODY><!--头部-->
<DIV class=ethainan>
<!--#include file="head.asp" -->

</DIV>

<!--头部结束--><!-- tag3开始 --><!-- tag3结束 -->
<DIV class=road_list>
<DIV class=pics_video>
<DIV class=show>
<UL>
  <H3><%= dh %></H3>
  <OL class=pics_video_v>
    <% call content() %>
    
    </OL></UL>
<P class=showbottom><SPAN></SPAN></P></DIV></DIV>
<DIV class=bbs_tool>
<DIV class=show>
<UL>
  <H3>热点阅读</H3>
  <OL class=zhinan_bbs>
   <%				dim rs1
					set rs1=server.CreateObject("adodb.recordset")
					sql="select top 7 * from jw_news where instr(fpath,',"&fid&",')>0 and show=0 order by hits desc"
					rs1.open sql,conn,1,1
					if rs1.eof then
						response.Write("还没有文章!")
					else
						do while not rs1.eof
				%>
  <LI><a href="show.asp?id=<%= rs1("id") %>"><%= cutstring(rs1("mc"),42) %></a></LI>
  <%
							rs1.movenext
						loop
					end if
%>
</OL></UL>
<P class=showbottom><SPAN></SPAN></P></DIV>
<DIV class="show zhinan_tool_magin">
<UL>
  <H3><SPAN>[<A 
  href="/newsclass.asp?fid=12">更多</A>]</SPAN>云南游记</H3>
  <OL class=zhinan_bbs>
  <%
sub news(xid,ts,zs)
set rs=conn.execute("select top "&ts&" * from jw_news where fid="&xid&" and show=0 order by zd desc,qz desc")
do while not rs.eof
%>
    <LI><a href="<%= getmc("jw_newsclass","id",rs("fid"),"newspath") %>?fid=<%= rs("fid") %>&amp;id=<%= rs("id") %>"><%= cutstring(rs("mc"),zs) %></a></LI>
    <%
rs.movenext
loop
call recordend(rs)
end sub

call news(12,4,32)
%>
</OL></UL>
<P class=showbottom><SPAN></SPAN></P></DIV>
<DIV class="show zhinan_tool_magin">
<UL>
  <H3><SPAN>[<A 
  href="/newsclass.asp?fid=16">更多</A>]</SPAN>旅游小知识</H3>
  <OL class=zhinan_bbs>
    <%
sub news(xid,ts,zs)
set rs=conn.execute("select top "&ts&" * from jw_news where fid="&xid&" and show=0 order by zd desc,qz desc")
do while not rs.eof
%>
    <LI><a href="<%= getmc("jw_newsclass","id",rs("fid"),"newspath") %>?fid=<%= rs("fid") %>&amp;id=<%= rs("id") %>"><%= cutstring(rs("mc"),zs) %></a></LI>
    <%
rs.movenext
loop
call recordend(rs)
end sub

call news(16,4,32)
%></OL></UL>
<P class=showbottom><SPAN></SPAN></P></DIV></DIV>
<DIV class=c></DIV></DIV><!--#include file="foot.asp" --></BODY></HTML>



<%
call connend()

sub content()
call record(rs,"select * from jw_news where instr(fpath,',"&fid&",')>0 and show=0 order by zd desc,"&order("jw_newsclass",fid),1)
dim n,pagetol,page,iid,i
n=16
if not rs.eof or rs.bof then
if Request("page")="" then 
page=1
else
page=CInt(Request("page"))'读取 URL 页号
end if
rs.PageSize=n '定义每页显示记录数
If page>rs.PageCount Then page=rs.PageCount 
If page<1 Then page=1 
if rs.recordcount>0 then
rs.AbsolutePage=page '定义当前页码
end if
pagetol=rs.pagecount

i=n
do while not rs.eof and i>0
%>
     <li><span><%= getriqi(rs("ctim")) %></span><% If len(rs("spic"))>5 Then %><font color="#3399CC">[图]</font><% End If %><a href="<%= getmc("jw_newsclass","id",rs("fid"),"newspath") %>?fid=<%= rs("fid") %>&id=<%= rs("id") %>"><%= rs("mc") %></a></li>
<%
i=i-1
rs.movenext
loop
end if
%>
    <li style="text-align:center; margin-top:5px; margin-bottom:5px;"><%= pagenum(page,rs.pagecount) %>   共 [ <font color="#0099CC"><strong><%= rs.recordcount %></strong></font> ] 篇文章</li>
<%
call recordend(rs)
end sub
%>