<!--#include file="inc/conn.asp"-->
<!--#include file="inc/config.asp"-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>新闻资讯 - <%=seo_home()%></title>
<link href="css/css.css" rel="stylesheet" type="text/css" />

</head>
<body>
<!--#include file="header.asp"-->

<div id="container">
<div id="wrapper">
<div id="mydefault">
<h1>新闻资讯</h1>
<div id="mydefault_content">
		<%
		id=request.QueryString("id")
		if id="" then
		sql="select  * from cms_new order by id desc"
		end if
		if id<>"" then
		sql="select  * from cms_new where fl="&id&" order by id desc"
		end if
		set rs=server.CreateObject("adodb.recordset")
		rs.open sql,conn,1,1 
		if rs.bof and rs.eof then
		response.Write("SORRY!没有任何内容，请管理员添加内容。")
		else
		rs.pagesize=20
		npagesize=rs.pagesize
		npagecount=rs.pagecount
		pageno=cint(request.QueryString("p"))
		if pageno=0 then
		pageno=1
		end if
		if pageno>npagecount then
		pageno=npagecount
		end if
		rs.absolutepage=pageno
		for i=1 to npagesize
		if rs.eof then
		exit for
		end if
		%>
		<div id="news-content">
            <h2><span><%=rs("times")%></span><a href="cont.asp?id=<%=rs("id")%>"><%=rs("title")%></a></h2>
        </div>
		 <%
		 rs.movenext
		 next
		 end if
		 %>	   
		   <p class="clear0">&nbsp;</p>
  <p id="page"><span class="k_pagelist">
  &nbsp;&nbsp;&nbsp;&nbsp;
  <%
  if pageno=1 then
  %>
  上一页&nbsp;&nbsp;
  <%else%>
  <a href="?p=<%=pageno-1%>">上一页</a>&nbsp;&nbsp;
  <%end if%>
  <%
	if pageno=npagecount then
	%>
	下一页&nbsp;&nbsp;
	<%else%>
  <a href="?p=<%=pageno+1%>">下一页</a>&nbsp;&nbsp;
  <%end if%>
    <select name="select" id="t" onchange="window.location='?p='+document.getElementById('t').value">
	  <%
	  for i=1 to npagecount
	  if i=pageno then
	  %>
        <option value="<%=i%>" selected="selected" >第<%=i%>页</option>
		<%else%>
		<option value="<%=i%>">第<%=i%>页</option>
		<%
		end if
		next
		%>
      </select>
  </p>
  
</div>
<p style="margin:0px; padding:0px; float:left; clear:left;"><img src="images/guanyu_bg.jpg" /></p>

</div>
</div>
<div id="nav">
<div id="feilei" >
<h2>新闻分类</h2>
<ul class="pro_list2">
		<%
		set ab=server.CreateObject("adodb.recordset")
		sql="select * from cms_newfl order by px_id"
		ab.open sql,conn,1,1
		if ab.bof and ab.eof then
		response.Write("SORRY!没有任何内容，请管理员添加内容。")
		else
		do while not ab.eof
		%>
		<li class="dalei">
		    <a href="/news.asp?id=<%=ab(0)%>"><%=ab("title")%></a>  
		</li>
		<%
		ab.movenext
		loop
		end if
		%>
</ul>
</div>

<div id="link">
<h4>联系我们</h4>
<ul>
<li>联系人：<%=seo_lianxi()%></li>
<li>电 话：<%=seo_dianhua()%></li>
<li>手 机：<%=seo_shouji()%></li>
<li>传 真：<%=seo_chuanzhen()%></li>
<li>Q&nbsp;&nbsp;&nbsp;Q：<%=seo_qq()%></li>
<li>地 址：<%=seo_diz()%></li>
</ul>
</div>
<p style="float:left; margin:0px; padding:0px; clear:left;"><img src="images/bg_about.jpg" /></p>
</div>	
	 </div>
<!--#include file="footer.asp"-->
</body>
</html>