📄 admin_dj.asp
字号:
for i=1 to request("count")
if not isempty(request("del"&i)) then
Conn.Execute("Delete * From [YC_djurl] Where id="&request("id"&i))
else
Conn.execute"update [YC_djurl] set url='"&request("url"&i)&"',title='"&request("urltitle"&i)&"',player='"&request("player"&i)&"',lcr='"&request("lcr"&i)&"' where id="&request("id"&i)
end if
next
for i=1 to request("no")
sql="select * from [YC_djurl] where (id is null)"
rsurl.open sql,conn,1,3
rsurl.addnew
rsurl("urlid")=urlid
rsurl("title")=replace(trim(request("urltitle"&(int(i)+int(request("count")))&"")),"'","")
rsurl("url")=replace(trim(request("url"&(int(i)+int(request("count")))&"")),"'","")
rsurl("player")=replace(trim(request("player"&(int(i)+int(request("count")))&"")),"'","")
rsurl("lcr")=replace(trim(request("lcr"&(int(i)+int(request("count")))&"")),"'","")
rsurl("num")=request("count")+i
rsurl.update
next
rsurl.close
set rsurl=nothing
rs7.close
set rs7=nothing
YCGO("admin_dj.asp")
case "pllist"
call pllist()
case "pledit"
set rs=server.CreateObject("adodb.recordset")
sql="select * from YC_pl where id="&request("id")
rs.open sql,conn,1,1%>
<form name="form1" method="post" action="?action=pleditok">
<table width="400" align=center border="0" cellpadding="0" cellspacing="0" bordercolor="<%=border%>" rules=none class=3d>
<tr><td height="22" class=title colspan=2><b> <img src=img/ie.gif border=0 width=15 height=15 align=absMiddle> 修改评论</b></td></tr>
<tr class=bg height=25><td> 评论者:</td><td><input name="title" type="text" id="title" value="<%=rs("title")%>" size="20" class=yecao style="width:120px"></td></tr>
<tr class=bg height=25><td valign=top> 内 容:</td><td><textarea name="content" style="width:300px;height:65px;" id="content"><%=rs("content")%></textarea></td></tr>
<tr class=bg height=25><td align=center colspan=2>
<input name="id" type="hidden" id="editpl" value="<%=rs("id")%>">
<input name="editpl" type="submit" id="editpl" value="修 改" class=adminbutton></form>
</td></tr></table>
<%case "pleditok"
set rs=server.CreateObject("adodb.recordset")
sql="select * from YC_pl where id="&request("id")
rs.open sql,conn,1,3
rs("title")=request.Form("title")
rs("content")=request.Form("content")
rs.update
response.Write "<script>alert('评论修改成功');</script>"
response.Write "<script>location.href='admin_dj.asp';</script>"
case else
call list()
end select
sub list()
sql="select * from YC_dj where error>0 order by id DESC"
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
errordj=rs.recordcount
rs.close
set rs=nothing
if request.querystring("class")<>"" then
sql="select * from [YC_dj] where class="&cint(request.querystring("class"))&" order by id desc"
elseif request.querystring("bigclass")<>"" then
sql="select * from [YC_dj] where bigclass="&cint(request.querystring("bigclass"))&" order by id desc"
elseif request.querystring("error")<>"" then
sql="select * from [YC_dj] where error=1 order by id desc"
elseif request.querystring("nopass")<>"" then
sql="select * from [YC_dj] where pass=0 order by id desc"
else
sql="select * from [YC_dj] order by id desc"
end if
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
%>
<table width="100%" align=center border="0" cellpadding="0" cellspacing="0" bordercolor="<%=border%>" rules=none class=3d>
<tr><td height="22" colspan="3" class=title><b> <img src=img/ie.gif border=0 width=15 height=15 align=absMiddle> 娱乐管理 [当前共有<%=YC(rs.recordcount)%>个娱乐,其中等待审核的有<%call nopasstable("YC_dj")%>个,网友报错的有<%=errordj%>个]</b>
<%if request.querystring("error")<>"" then%>
 [<a href="?action=goerrorok"><font color=#ffffff>全部修复错误</font></a>] <%end if%>
</td><td colspan="2">
<%call showclass("YC_djclass","娱乐","admin_dj.asp")%></td></tr>
<tr class=bg height="25">
<form method="post" name="form" id="form" action="del.asp" onsubmit="return downdel();">
<td width="5%" align=center>选定</td>
<td width="65%" align=center>标题</td>
<td width="10%"align=center>审核</td>
<td width="5%"align=center>点击</td>
<td width="20%" align=center>操作</td></tr>
<tr><td class="hr" colspan="5"></td></tr>
<%
if not rs.bof and not rs.eof then
rs.pagesize=cint(adminpage)
i=1
mypage=request("page")
if mypage="" then
mypage=1
else
mypage=cint(mypage)
end if
pages=rs.pagecount
rs.absolutepage=mypage
do while not rs.eof%>
<tr height=25 class=bg onmouseout="this.style.backgroundColor=''" onmouseover="this.style.backgroundColor='#efefef'">
<td align=center>
<input name='SoftID' type='checkbox' onclick="unselectall()" id="SoftID" value='<%=rs("id")%>'></td>
<td>
<font color="<%=rs("color")%>"><%=rs("title")%></font> <%if rs("best")=1 then%>『<font color=red>推荐</font>』<%end if%> 
<%if rs("pass")=0 then%>
<button class=button onclick="{if(confirm('您再次确定要删除『<%=rs("user")%>』发布的这条新闻吗?\n\n注意:删除后不可恢复,并且会扣掉『<%=rs("user")%>』的10点!')){window.location='?action=delnopass&user=<%=rs("user")%>&id=<%=rs("id")%>'}return false;}">不通过</button>
<%end if%><%if request.querystring("error")<>"" then%>
<a href="?action=eok&id=<%=rs("id")%>"><b><font color=red>修复错误</font></b></a><%end if%></td><td width="10%"align=center><%if rs("pass")=0 then%><font color=red><b>等待</b></font><%else%>通过<%end if%>
</td>
<td align=center><%=rs("click")%></td>
<td> <a href="?action=edit&id=<%=rs("id")%>">编辑</a>
<a href="showdj.asp?id=<%=rs("id")%>" target=_blank>查看</a> <%response.Write adminpl("dj",rs("id"))%></td></tr>
<tr><td class="hr" colspan="5"></td></tr>
<%
if i=rs.pagesize then exit do end if
i=i+1
rs.movenext
loop
end if
if rs.eof and rs.bof then
Response.Write("<tr class='bg' height='200'><td align=""center"" colspan=""5"">暂无数据……</td></tr>")
else%>
<tr class=bg><td height=25 colspan="5">
<table width=100% border=0><tr><td width=200>
<input name="chkAll" type="checkbox" id="chkAll" onclick=CheckAll(this.form) value="checkbox">
<input name="submit" type="submit" onClick="document.form.Action.value='Del'" value="删 除" class=adminbutton>
<input name="Action" type="hidden" id="Action" value="Del">
<input name="tab" type="hidden" id="tab" value="YC_dj">
<input name="urltab" type="hidden" id="urltab" value="YC_djurl">
<input name="url" type="hidden" id="url" value="admin_dj.asp">
</td><td>
  共有娱乐<font color=red><%=rs.recordcount%></font>条,每页<font color=red><%=rs.pagesize%></font>条,分<font color=red><%=mypage%></font>/<%=rs.pagecount%>页   
<script language="javascript">
<%if request.querystring("error")<>"" then%>
showPageLink("?action=list&error=error&class=<%=request("class")%>&page=",<%=mypage%>,<%=pages%>);
<%else%>
showPageLink("?action=list&class=<%=request("class")%>&page=",<%=mypage%>,<%=pages%>);
<%end if%>
</script>
</td></tr></table>
<%end if%>
</td></tr>
</form></table>
<%
rs.close
set rs=nothing
end sub
sub pllist()%>
<table width="100%" align=center border="0" cellpadding="0" cellspacing="0" bordercolor="<%=border%>" rules=none class=3d>
<tr><td height="22" colspan="6" class=title><b> <img src=img/ie.gif border=0 width=15 height=15 align=absMiddle> 评论管理 [关于《
<%
set rs=server.CreateObject("adodb.recordset")
sql="select * from [YC_dj] where id="&request("plid")
rs.open sql,conn,1,1
response.Write rs("title")
rs.close
set rs=nothing
%>》
的评论]</b></td></tr>
<tr class=bg height="25">
<form method="post" name="form" id="form" action="del.asp" onsubmit="return downdel();">
<td width="5%" align=center>选定</td>
<td width="50%" align=center>评论内容</td>
<td width="25%"align=center>评论者</td>
<td width="15%" align=center>操作</td></tr><tr><td class="hr" colspan="6"></td></tr>
<%
sql="select * from YC_pl where pltype='dj' and plid="&request("plid")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
if not rs.bof and not rs.eof then
rs.pagesize=cint(adminpage)
i=1
mypage=request("page")
if mypage="" then
mypage=1
else
mypage=cint(mypage)
end if
pages=rs.pagecount
rs.absolutepage=mypage
do while not rs.eof%>
<tr height=25 class=bg onmouseout="this.style.backgroundColor=''" onmouseover="this.style.backgroundColor='#efefef'">
<td align=center>
<input name='SoftID' type='checkbox' onclick="unselectall()" id="SoftID" value='<%=rs("id")%>'></td>
<td><%=rs("content")%></td>
<td align=center><%=rs("title")%></td>
<td align=center><a href="?id=<%=rs("id")%>&action=pledit">编辑</a></td></tr><tr><td class="hr" colspan="6"></td></tr>
<%
if i=rs.pagesize then exit do end if
i=i+1
rs.movenext
loop
end if
if rs.eof and rs.bof then
response.write"<tr><td colspan=6 height=100 align=center>暂时没有娱乐评论!</td></tr>"
else%>
<tr class=bg><td height=25 colspan=6>
<table width=100% border=0><tr><td width=200>
<input name="chkAll" type="checkbox" id="chkAll" onclick=CheckAll(this.form) value="checkbox">
<input name="submit" type="submit" onClick="document.form.Action.value='Del'" value="删 除" class=adminbutton>
<input name="Action" type="hidden" id="Action" value="Del">
<input name="tab" type="hidden" id="tab" value="YC_pl">
<input name="url" type="hidden" id="url" value="admin_dj.asp">
</td><td>
  共有娱乐评论<font color=red><%=rs.recordcount%></font>条,每页<font color=red><%=rs.pagesize%></font>条,分<font color=red><%=mypage%></font>/<%=rs.pagecount%>页   
<script language="javascript">
showPageLink("?action=pllist&page=",<%=mypage%>,<%=pages%>);
</script>
</td></tr></table>
<%end if%>
</td></tr>
</form></table>
<%
rs.close
set rs=nothing
end sub
call closedata()%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -