<%
response.expires=0

if session("zkpicksysuser")="" then
  response.redirect "index.asp"
  response.end
end if
%>
<!--#include file="dbinc/dbpath.asp" -->
<%
const MaxPrePage=20  '每页显示记录数

if (request.querystring("page")<>"") and (IsNumeric(request.querystring("page"))) then  '检查页号
  intPage=CLng(request.querystring("page"))
else
  intPage=1
end if

strSql="select * from news "
if (request.querystring("show")<>"") and (IsNumeric(request.querystring("show"))) then  '检查网站等级
  intshow=CLng(request.querystring("show"))
else
  intshow=1
end if




if (request.querystring("diyu")<>"") and (IsNumeric(request.querystring("diyu"))) then  '检查是否地域分类
  intType=CLng(request.querystring("diyu"))
  strSql=strSql& " and pickdiyu="&CLng(request.querystring("diyu"))
else
  intType=0
end if

strSql=strSql&" order by newsid desc"
%>
<html>
<head>
<title>3鸟设社网站评测 — 管理中心</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="link.css">
<script language="JavaScript">
<!--
function winpop(id)
{
  window.open('sysshow.asp?id='+id,'','toolbar=no,location=no,status=no,menubar=no,scrollbars=auto,resizable=yes,width=520,height=200,top=100,left=100');
}
// --> 
</script>
</head>

<body bgcolor="#FFFFFF" topmargin="2" marginheight="2" leftmargin="2" marginwidth="2">
<table width="754" border="0" cellspacing="0" cellpadding="0" bordercolorlight="#FF6633" bordercolordark="#FFFFFF" class="9p" align="center">
  <tr valign="bottom" bgcolor="#FFCC00"> 
    <td height="2" bgcolor="#D0FDDA"> 
      <div align="center"><font color="#cc3366">〓〓</font> <font color="#000000">管理中心</font><font color="#cc3366">〓〓</font> 
        <font color="#cc3366">&nbsp;□→</font> <a href="syslist.asp?show=1">加盟网站</a> 
        <font color="#cc3366">&nbsp;□→ </font><a href="syslist.asp?show=2">认证网站</a> 
        <font color="#cc3366">&nbsp;□→ </font><a href="syslist.asp?show=3">特色网站</a> 
        <font color="#cc3366">&nbsp;□→ </font><a href="syslist.asp?show=4">推荐网站</a> 
        <font color="#cc3366">&nbsp;□→ </font><a href="syslist.asp?show=5">精品网站</a> 
        <font color="#cc3366">□→<a href="newssyslist.asp">新闻管理</a> □→ <a href="index.asp">退出管理</a>〓〓</font></div>
    </td>
  </tr>
</table>
<table width="500" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
    <td> 
      <% 
set rs=createobject("adodb.recordset") 
rs.open strSql,conn,1,3 
if rs.eof and rs.bof then 
  response.write "<div align='center'><font color='#cc3366'>对不起，暂时还没有相关网站，请稍后进行网站鉴定！</font></div>" 
else 
 
rs.pagesize=MaxPrePage 
if intPage>rs.pagecount then  
  intPage=rs.pagecount 
end if  
%>
      <table width="500" border="0" cellspacing="0" cellpadding="0" class="9p" align="center">
        <tr bgcolor="#FFCC99" valign="bottom"> 
          <td height="18" bgcolor="#006699"> 
            <div align="right"><font color="#FFFFFF"> 
              <% displayPagelinks rs,intPage,intType,intshow %>
              &nbsp;</font></div>
          </td>
        </tr>
        <tr> 
          <td class="4p">&nbsp;</td>
        </tr>
        <tr> 
          <td> 
            <table width="500" border="1" cellspacing="0" cellpadding="0" bordercolorlight="#999999" bordercolordark="#FFFFFF" class="9p">
              <tr> 
                <td width="483" bgcolor="#CCCCCC"> 
                  <div align="center">新闻标题</div>
                </td>
                <td width="131" bgcolor="#CCCCCC"> 
                  <div align="center">操作</div>
                </td>
              </tr>
              <% 
rs.absolutepage=intPage 
for i=1 to rs.pagesize 
%>
              <tr> 
                <td width="483"><a href="viewnews.asp?id=<%=rs("newsid")%>" target="_blank"> 
                                <% if len(rs("biaoti"))>18 then%>
                                <%=left(rs("biaoti"),15)%>... 
                                <% else%>
                                <%=rs("biaoti")%> 
                                <%end if%> </a>                </td>
                <td width="131"> 
                  <div align="center"><%response.write "<a href='newsbj.asp?id="&rs("newsid")&"'><font color='#cc3366'>编辑</font></a>"%> | 
                    <%response.write "<a href='newsdele.asp?id="&rs("newsid")&"'><font color='#cc3366'>删除</font></a>"%>
                  </div>
                </td>
              </tr>
              <% 
rs.movenext 
if rs.eof then exit for 
next %>
            </table>
          </td>
        </tr>
        <tr> 
          <td class="4p">&nbsp;</td>
        </tr>
        <tr bgcolor="#FFCC99" valign="bottom"> 
          <td height="18" bgcolor="#006699"> 
            <div align="right"><font color="#FFFFFF"> 
              <% displayPagelinks rs,intPage,intType,intshow %>
              &nbsp;</font></div>
          </td>
        </tr>
      </table>
      <% end if %>
    </td>
  </tr>
</table>

</body> 
</html> 
<% 
Sub DisplayPagelinks(rs,intPage,intType,intshow)   '页面导航条 
'------------------------------- 
response.write "共"&rs.RecordCount&"条新闻 " 
 
if  intPage>1 then 
  if intType<>0 then 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?type="&intType&"&show="&intshow&"&page=1""><font color='#FFFFFF'>首页</font></a> " 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?type="&intType&"&show="&intshow&"&page="&intPage-1&"""><font color='#FFFFFF'>上一页</font></a> "     
  else 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?show="&intshow&"&page=1""><font color='#FFFFFF'>首页</font></a> " 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?show="&intshow&"&page="&intPage-1&"""><font color='#FFFFFF'>上一页</font></a> " 
  end if 
else 
  response.write "首页 "   
  response.write "上一页 " 
end if 
 
if intPage < rs.PageCount then 
  if intType<>0 then 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?type="&intType&"&show="&intshow&"&page="&intPage+1&"""><font color='#FFFFFF'>下一页</font></a> " 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?type="&intType&"&show="&intshow&"&page="&rs.PageCount&"""><font color='#FFFFFF'>尾页</font></a> " 
  else 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?show="&intshow&"&page="&intPage+1&"""><font color='#FFFFFF'>下一页</font></a> " 
    response.write "<a href="""&request.ServerVariables("SCRIPT_NAME")&"?show="&intshow&"&page="&rs.PageCount&"""><font color='#FFFFFF'>尾页</font></a> " 
  end if 
else 
  response.write "下一页 " 
  response.write "尾页 " 
end if 
 
'------------------------------- 
End Sub 
%> 
<% 
rs.close 
set rs=nothing 
conn.close 
set conn=nothing 
%> 