<!--#include file="Config.asp" -->
<!--#include file="Conn.asp" -->
<!--#include file="chkuser.asp" -->
<HTML><HEAD><TITLE>小类管理 </TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<link rel="stylesheet" href="admin.css" type="text/css">
<SCRIPT LANGUAGE=javascript>
<!--
function SelectAll() {
	for (var i=0;i<document.selform.newsID.length;i++) {
		var e=document.selform.newsID[i];
		e.checked=!e.checked;
	}
}
//-->
</script>
</HEAD>
<BODY  leftMargin=0>
<%
set Rs0=server.createobject("adodb.recordset")
rs0.open "select * from dv_user where username='"&UserName&"'",conn,1,1
if not(rs0.bof and rs0.eof) then
bigclass_quanxian=rs0("bigclass_quanxian")
smallclass_quanxian=rs0("smallclass_quanxian")
end if
rs0.close
set rs0=nothing

 dim sql,rs,subrs
 %>
<table width="95%" border="0" align="center" cellpadding="3" cellspacing="1" class="tableBorder">
 <th>点击相应栏目名添加文章</th>
          <% 
		  if bigclass_quanxian <> "" then
		  set Rs=server.createobject("adodb.recordset")
		set SubRs=server.createobject("adodb.recordset")
		 rs.open "select * from bigclass where bigclassid in ("&bigclass_quanxian&") order by bigclassorder",conn,1,1
	          if not(rs.bof and rs.eof) then
			  do while not rs.eof %>
          <tr>             
      <td  bgcolor="#D4DEF9" height="25">&nbsp; <font color="#FF0000"><b><%=rs("bigclassorder")%>、</b></font><a href="news_add.asp?bigclassID=<%=Rs("bigclassID")%>&bigclassname=<%=Rs("bigclassname")%>"><b><%=rs("bigclassName")%></b></a> </td>
          </tr>
		  <%
		  if smallclass_quanxian<>"" then
		  %>
          <tr> 
            
      <td class="forumRow"  height="25"> 
        <% SubRs.open "select * from smallclass where smallclassid in ("&smallclass_quanxian&") and bigclassID="&Rs("bigclassID")&" order by smallclassorder asc",conn,1,1
        if err.number <> 0 then
	           response.write "数据库出错"
           else
	           if SubRs.bof and SubRs.eof then
		        response.write "&nbsp; 没有小类"
	           else
			   i=1
			 do while not SubRs.eof 			 
			 %> <%=SubRs("smallclassorder")%>、<a href="news_add.asp?smallclassID=<%=SubRs("smallclassID")%>&bigclassID=<%=Rs("bigclassID")%>&bigclassname=<%=Rs("bigclassname")%>&smallclassname=<%=SubRs("smallclassname")%>" class="ArticleList"><%=SubRS("smallclassName")%></a> <% if (i mod 7)=0 then response.write "<br>"
			i=i+1
			SubRs.movenext
	               loop
	           end if
  end if
  SubRs.close
  %> </td>
          </tr>
          <%
		  end if
		   rs.movenext
	        loop
		   end if
		 rs.close
		 set subrs=nothing
		 set rs=nothing
		 else
	%>
	<tr>             
      <td  bgcolor="#D4DEF9" height="55" align="center">对不起您还没有任何栏目的管理权限！</td>
          </tr>
		  <%end if%>
      </table>
 </BODY></HTML>
