⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 admin_articlepas.asp

📁 大榕树网络文章管理系统
💻 ASP
字号:
<%
Option Explicit
Response.buffer=true
const purviewlevel=5
%>
<!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">
<!--#include file="admin_PurviewChe.asp" -->
<!--#include file="conn.asp" -->
<%
dim arid,passed,rspas,id
arid=trim(request.querystring("articleid"))
id=trim(request.form("ID"))
passed=trim(request("passed"))
if passed="pass" then

if arid<>"" then
set rspas=server.createobject("ADODB.Recordset")
rspas.open"select articleid,passed from article where articleid="&arid&"",conn,1,3
rspas("passed")=true
rspas.update
rspas.close
set rspas=nothing
else
if id<>"" then
dim n,h
n=split(id,",")
for h=0 to ubound(n)
conn.execute"update article set passed=true where articleid="&n(h)
next
end if
end if
end if
%>
<!--#include file="../inc/function.asp"-->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>审核文章面板</title>
<link href="Style.css" rel="stylesheet" type="text/css">
<script language=javascript>
function unselectall()
{
    if(document.passed.chkAll.checked){
	document.passed.chkAll.checked = document.passed.chkAll.checked&0;
    } 	
}

function CheckAll(form)
  {
  for (var i=0;i<form.elements.length;i++)
    {
    var e = form.elements[i];
    if (e.Name != "chkAll")
       e.checked = form.chkAll.checked;
    }
  }
</script>
</head>

<body>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr>
    <td align="center" class="txt1">欢迎来到文章审核面板</td>
  </tr>
  <tr>
    <td align="center" class="txt05">单击[修改]可设定文章的各种属性,单击文章标题可预览文章的各项属性。[<a href="admin_ArticleMan.asp">管理文章面板</a>][<a href="admin_ArticleAdd.asp">添加新文章</a>]</td>
  </tr>
  <tr>
    <td><form name="passed" method="post" action="admin_ArticlePas.asp?passed=pass">
      <table width="99%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#EDF1EF">
        <tr class="txt1">
          <td colspan="7"><span class="txt03">--请选择所属专题:
              <select name="special" class="but" size="1" onChange="window.open(this.options[this.selectedIndex].value,'_self')">
                <option>请选择所属专题</option>
                <%dim rsspecial
			set rsspecial=conn.execute("select specialid,special from special order by specialid desc")
			if rsspecial.eof or rsspecial.bof then
			%>
                <option>还没有专题</option>
                <%else 
			do while not rsspecial.eof%>
                <option value="admin_ArticlePas.asp?special=<%=rsspecial("special")%>"><%=rsspecial("special")%></option>
                <%rsspecial.movenext
			loop
			end if
			%>
              </select>
              <br>
--请选择所属大类:
<%
		  dim rsbig
		  set rsbig=server.createobject("ADODB.Recordset")
		  rsbig.open"select * from bigclass order by bigclassid desc",conn,1,1
		  if rsbig.eof or rsbig.eof then
		  response.write"还没有大类栏目"
		  rsbig.close
		  set rsbig=nothing
		  else
		  do while not rsbig.eof
		  response.write"『<a href='admin_ArticlePas.asp?bigclass="&rsbig("bigclass")&"'>"&rsbig("bigclass")&"</a>』"		 
		  rsbig.movenext
		  loop
		  response.write"<br>"
		  rsbig.close
		  set rsbig=nothing
		  end if %>
<%
          dim rsar,page,i,articleid,filepath,rssmall,bigclass,smallclass,special
          special=trim(request("special"))
          bigclass=trim(request("bigclass"))
          smallclass=trim(request("smallclass"))
          if bigclass<>"" then
          set rssmall=server.createobject("ADODB.Recordset")
		  rssmall.open"select * from smallclass where bigclass='"&bigclass&"'",conn,1,1
		  if rssmall.eof or rssmall.bof then
		  response.write"--请选择所属小类:"
		  response.write"还没有小类栏目"
		  rssmall.close
		  set rssmall=nothing
		  else
		  response.write"--请选择所属小类:"
		  do while not rssmall.eof 
		  response.write"[<a href='admin_ArticlePas.asp?bigclass="&bigclass&"&smallclass="&rssmall("smallclass")&"'>"&rssmall("smallclass")&"</a>]"
		  rssmall.movenext
		  loop
		  rssmall.close
		  set rssmall=nothing
		  end if
		  end if
		  %>
          </span></td>
        </tr>
        <tr align="center" class="txt1">
          <td colspan="7" class="txt1"><span class="txt03">
          <%  
set rsar=server.createObject("ADODB.Recordset")
if special<>"" then
rsar.open"select articleid,title,author,updatetime,bigclass,includepic,ontop,elite,hot,hits,textclass,passed from article where special='"&special&"' and passed=false order by articleid desc",conn,1,1         
else
if bigclass<>"" and smallclass="" then
rsar.open"select articleid,title,author,updatetime,bigclass,includepic,ontop,elite,hot,hits,textclass,passed from article where bigclass='"&bigclass&"' and passed=false order by articleid desc",conn,1,1         
else 
if bigclass<>"" and smallclass<>"" then
rsar.open"select articleid,title,author,updatetime,bigclass,includepic,ontop,elite,hot,hits,textclass,passed from article where bigclass='"&bigclass&"' and smallclass='"&smallclass&"' and passed=false order by articleid desc",conn,1,1
else
rsar.open"select articleid,title,author,updatetime,bigclass,includepic,ontop,elite,hot,hits,textclass,passed from article where passed=false order by articleid desc",conn,1,1
end if
end if
end if
if rsar.eof or rsar.bof then
response.write"<div align='center'>还没有文章可管理,请添加新文章!</div>"
response.end()
else
%>
          <%filepath=request.servervariables("path_info")%>
          <%
page=request.querystring("page")
rsar.pagesize=15
if not isempty(page) then
   if not isnumeric(page) then
     page=1
	 else
	 page=cint(page)
	 end if
	 if page>rsar.pagecount then
	    rsar.absolutepage=rsar.pagecount
		elseif page<=0 then
		rsar.absolutepage=1
		else
		  rsar.absolutepage=page
		  end if
		else
	rsar.absolutepage=1
	end if
	page=rsar.absolutepage
%>
          <%call pagination(rsar.pagecount,rsar.pagesize,page,rsar.recordcount)%>
          </span></td>
          </tr>
        <tr align="center" class="tbbgtitle">
          <td width="6%" class="tbbgtitle">选定</td>
          <td width="6%" class="tbbgtitle">ID号</td>
          <td width="36%" class="tbbgtitle">文章标题</td>
          <td width="8%" class="tbbgtitle">作者</td>
          <td width="9%" class="tbbgtitle">文章属性</td>
          <td width="9%" class="tbbgtitle">等级</td>
          <td width="8%" class="tbbgtitle">审核</td>
        </tr>
        <% for i=1 to rsar.pagesize
	      if rsar.eof then
		  exit for
		  end if %>
        <tr align="center" class="txt02">
          <td class="tbbgtitle"><input name='ID' type='checkbox' class="but" id="ID" onClick="unselectall()" value='<%=rsar("articleID")%>'></td>
          <td><%=rsar("articleid")%></td>
          <td>
		  <%if rsar("includepic")=true then
		  %><span class="txt06">[图]</span>
            <%end if%><a href="admin_ArticleRead.asp?articleid=<%=rsar("articleid")%>" target="_blank" title="标题:<%=rsar("title")%>//作者:<%=rsar("author")%> //添加时间:<%=rsar("updatetime")%>//点击数:<%=rsar("hits")%>">
		  <%if len(rsar("title"))>20 then
		    response.write""&left(rsar("title"),20)&"…"
			else
			response.write""&rsar("title")&""
			end if
		  %></a></td>
          <td><%=rsar("author")%></td>
          <td><%if rsar("ontop")=1 then%>
  <%end if%>
  <%if rsar("elite")=2 then%>
<%end if%>
<%if rsar("hot")=3 then%>
<%end if%>
&nbsp;</td>
          <td><%select case rsar("textclass")
	         case "0"
			 response.write"一般游客"
			 case "1"
			 response.write"注册用户"
			 case "2"
			 response.write"普通会员"
			 case "3"
			 response.write"中级会员"
			 case "4"
			 response.write"高级会员"
			 case "5"
			 response.write"特级会员"
			 end select	
	%></td>
          <td><span class="txt05"><a href="admin_ArticlePas.asp?articleid=<%=rsar("articleid")%>&passed=pass">审核</a></span>
            <input name="passed" type="hidden" id="passed3" value="pass"></td>
        </tr><% rsar.movenext
	    next
	    %>
        <tr align="center" class="txt02">
          <td colspan="7" class="txt1"><span class="txt03">
            <%call pagination(rsar.pagecount,rsar.pagesize,page,rsar.recordcount)%>
          </span></td>
        </tr>
        <tr align="center" class="txt02">
          <td colspan="7" ><span class="txt05">
            <input name="chkAll" type="checkbox" class="but" id="chkAll" onclick=CheckAll(this.form) value="checkbox">
            选中本页所有文章
          </span>
            <input name="Submit" type="submit" class="but" value="审核通过选中的文章"> </td>
          </tr>
      </table>
    </form></td>
  </tr>
</table>
</body>
</html>

<%end if

rsar.close
set rsar=nothing
call closeconn()
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -