<script type="text/JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
//-->
</script>
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td align="center" style="padding-bottom:5px;padding-top:5px">
	<fieldset style="width:100%px;height:100px" align="left" bordr="1">
	<table width="98%" border="0" cellspacing="0" cellpadding="0" style="padding-top:10px">
      <tr>
        <td>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<%'自动提取打开文章所属频道的最后10条记录主题
dim u,m,l,url
u=request.ServerVariables("URL")
m=split(u,"/")
l=split(m(2),"list")
set rsurl=server.createobject("adodb.recordset")
rsurl.open"select top 12 * from "&l(0)&" order by updatetime desc",conn,1,1
while not rsurl.eof%>
<tr><td>
<%if rsurl("titletype")<>"" then '如果是外部链接
response.Write"<a href='"&rsurl("titletype")&"' target='_blank'>"&left(rsurl("title"),18)&"</a>"
else
response.Write"<a href='"&l(0)&"list.asp?id="&rsurl("newsid")&"' target='_blank'>"&left(rsurl("title"),18)&"</a>"
end if
rsurl.movenext%>
</td><td>
<%if rsurl("titletype")<>"" then '如果是外部链接
response.Write"<a href='"&rsurl("titletype")&"' target='_blank'>"&left(rsurl("title"),18)&"</a>"
else
response.Write"<a href='"&l(0)&"list.asp?id="&rsurl("newsid")&"' target='_blank'>"&left(rsurl("title"),18)&"</a>"
end if%>
</td></tr>
<%rsurl.movenext
wend
rsurl.close
set rsurl=nothing%>
<tr><td colspan="2">
<marquee direction="left" height="20" width="100%">
<%set rs1=server.createobject("adodb.recordset")
rs1.open"select top 3 * from news_dir order by updatetime desc",conn,1,1
while not rs1.eof
if rs1("titletype")<>"" then '是否外部链接
response.Write"<a href='"&rs1("titletype")&"' target='_blank'><font color='red'>"&rs1("title")&"</font></a>&nbsp;"
else
response.Write"<a href='news_dirlist.asp?id="&rs1("newsid")&"' target='_blank'><font color='red'>"&rs1("title")&"</font></a>&nbsp;"
end if
rs1.movenext
wend
rs1.close
set rs1=nothing%></marquee>
</td>
</tr></table>
		</td>
        <td align="right">
<%'文章画中画广告
dim murl
murl=split(request.ServerVariables("URL"),"/")
b=split(ggother("1443"),".")
a=split(ggother("1443url"),",")
if ggother("1443")="" then
elseif b(1)="swf" then%>
<embed src="<%=ggother("1443")%>" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="<%=a(0)%>" height="<%=a(1)%>"></embed>
<%elseif b(1)="jpg" or b(1)="gif" then%>
<a href="<%=a(2)%>" target="_blank"><img src="<%=ggother("1443")%>" width="<%=a(0)%>" height="<%=a(1)%>" border="0"></a>
<%end if%></td></table></fieldset>
  </td></tr>
<%'判断是否存在分页，并显示分页菜单
dim c,p
c=split(rs("content"),"[nextpage]")
p=ubound(c)+1
if p>1 then%>
  <tr>
    <td style="padding-bottom:5px;padding-top:15px"><select name="menu1" onchange="MM_jumpMenu('parent',this,0)" style="width:220;border-width:thin">
<%if request("page")="" then%>
<option>第1页：<%=left(c(0),30)%></option>
<%else%>
<option>第<%=request("page")%>页：<%=left(c(request("page")-1),30)%></option>
<%end if
dim r
for r=0 to p-1%>
<option value="<%=request.servervariables("URL")%>?id=<%=request("id")%>&page=<%=r+1%>" >
第<%=r+1%>页：<%=left(c(r),30)%></option>
<%next%>
    </select></td>
  </tr>
<%end if%>
  <tr> 
    <td style="padding-left:5px;padding-right:5px;padding-top:15px">
    <%'显示文章内容
    dim Content,CurrentPage,pages,i
    Content=rs("Content")
	CurrentPage=trim(request("Page"))
    if Instr(rs("Content"),"[nextpage]")<=0 then
    response.write Content
	else
    Contentstr=split(rs("Content"),"[nextpage]")
    pages=Ubound(Contentstr)+1
    if CurrentPage="" then
    CurrentPage=1
    else
    CurrentPage=Cint(CurrentPage)
    end if
	if CurrentPage<1 then CurrentPage=1
    if CurrentPage>pages then CurrentPage=pages
	response.write Contentstr(CurrentPage-1)%></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
  <tr> 
    <td align="center" bgcolor="#E8E8E8" style="padding-top:5px"> 
      <%if CurrentPage>1 then%>
      <a href="<%=request.servervariables("URL")%>?id=<%response.write id %>&page=<%response.write currentpage-1 %>" class="page">上一页</a> 
      <%end if
        for i=1 to pages
        if i=CurrentPage then%>
      <font color="#FF0000" size="small"><%=(i)%></font> 
      <%else%>
      <a href="<%=request.servervariables("URL")%>?id=<%response.write id %>&page=<%=i%>" class="page"><%=i%></a> 
      <%end if
        next
		if CurrentPage<pages then%>
      <a href="<%=request.servervariables("URL")%>?id=<%response.write id %>&page=<%response.write currentpage+1 %>" class="page">下一页</a> 
      <%end if
end if %></td>
  </tr>
</table>
