?? qwbm_book.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%><!--#include file="qwbm_conn.asp"--><!--#include file="qwbm_cheack.asp"--><%
if request("action")="shen" then
ssql="select * from qwbmbook where id="&request("id")
set srs=server.CreateObject("adodb.recordset")
srs.open ssql,conn,1,3
if request("shenhe")=1 then
srs("shenhe")=0
else
srs("shenhe")=1
end if
srs.update
srs.close
set srs=nothing
response.redirect ("qwbm_book.asp")
response.end()
end if
objasp = trim(request("asp"))
if objasp="allysh" then
ddx=Request("adid")
if (ddx = "") then
call errbox("請選擇審核的條目","qwbm_book.asp","","","")
else
dddSQL="Update [book] set shenhe=1 where id in ("&ddx&")"
conn.Execute (dddSQL)
response.redirect "qwbm_book.asp?page="&request("page")&""
response.end
end if
end if
if objasp="allnsh" then
ddx=Request("adid")
if (ddx = "") then
call errbox("請選擇不審核的條目","qwbm_book.asp","","","")
else
dddSQL="Update [book] set shenhe=0 where id in ("&ddx&")"
conn.Execute (dddSQL)
response.redirect "qwbm_book.asp?page="&request("page")&""
response.end
end if
end if
if objasp="alldel" then
dde=Request("adid")
if (dde = "") then
call errbox("請選擇要刪除的條目","qwbm_book.asp","","","")
else
dddSQL="Delete * from [book] where id in ("&dde&")"
conn.Execute (dddSQL)
response.redirect "qwbm_book.asp?page="&request("page")&""
response.end
end if
end if
if request("action")="bookhui" then
dim name,liuyan,hui,huitime,shenhe
name=trim(request("name"))
liuyan=replacehtml(trim(request("liuyan")))
hui=replacehtml(trim(request("hui")))
huitime=trim(request("huitime"))
shenhe=trim(request("shenhe"))
if shenhe="" then
shenhe=0
end if
phsql="select * from qwbmbook where id="&request("id")
set phrs=server.createobject("adodb.recordset")
phrs.open phsql,conn,1,3
phrs("name")=name
phrs("liuyan")=liuyan
phrs("hui")=hui
phrs("huitime")=huitime
phrs("shenhe")=shenhe
phrs.update
phrs.close
set phrs=nothing
response.write "<script>alert(""回復留言成功"");window.location='qwbm_book.asp';</script>"
response.end()
end if
if request("action")="del" then
dsql="delete * from qwbmbook where id="&request("id")
set drs=server.createobject("adodb.recordset")
drs.open dsql,conn,1,3
drs.update
response.redirect("qwbm_book.asp")
end if
%><!--
'☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆
'★ ★
'☆ 深山行者文章管理系統V1.0版本 ☆
'★ ★
'☆ 版權所有: http://www.qwbm.com ☆
'★ ★
'☆ 程序制作: 深山行者 ☆
'★ http://www.qwbm.com ★
'☆ QQ:565449214 ☆
'★ ★
'☆ ☆
'★ 主頁地址: http://www.qwbm.com 深山行者個人網站 ★
'★ ★
'☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆
-->
<!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>深山后臺留言管理頁面</title>
<link rel="stylesheet" type="text/css" href="skin/01/images/css.css">
<script language="javascript" type="text/javascript" src="js/js.js"></script>
</head>
<body>
<%if request("action")="hui" then%>
<%
hsql="select * from qwbmbook where id="&request("id")
set hrs=server.CreateObject("adodb.recordset")
hrs.open hsql,conn,1,1
if hrs.eof and hrs.bof then
response.Write ""
else
%>
<div class="divm"><strong><a href="qwbm_book.asp"><span class="tdf4">取消添加回復,返回管理頁面</span></a></strong><div class="divml"></div><div class="divmr">留言回復頁面</div></div>
<form name="form2" method="post" action="?action=bookhui&id=<%=request("id")%>">
<table cellpadding="0" cellspacing="1" class="table1">
<tr>
<td class="td1">網友大名:</td>
<td class="td2"><input name="name" type="text" class="input" size="40" id="name" value="<%=hrs("name")%>"></td>
</tr>
<tr>
<td class="td1">網友seid:</td>
<td class="td2"><input name="sessid" type="text" class="input" size="40" id="sessid" value="<%=hrs("sessid")%>"></td>
</tr>
<tr>
<td class="td1">網友 IP:</td>
<td class="td2"><input name="ip" type="text" class="input" size="40" id="ip" value="<%=hrs("ip")%>"></td>
</tr>
<tr>
<td class="td1">評論時間:</td>
<td class="td2"><input name="liuyantime" type="text" class="input" size="40" id="liuyantime" value="<%=hrs("liuyantime")%>"></td>
</tr>
<tr>
<td class="td1">評論內容:</td>
<td class="td2"><textarea name="liuyan" cols="60" rows="6" class="textarea" id="input_text"><%=relasehtml(hrs("liuyan"))%></textarea></td>
</tr>
<tr>
<td class="td1">回復時間:</td>
<td class="td2"><input name="huitime" type="text" class="input" size="40" id="hui" value="<%=now()%>"></td>
</tr>
<tr>
<td class="td1">回復內容:</td>
<td class="td2"><textarea name="hui" cols="60" rows="6" class="textarea" id="input_text"><%=relasehtml(hrs("hui"))%></textarea></td>
</tr>
<tr>
<td class="td1">是否審核:</td>
<td class="td2"><input name="shenhe" type="checkbox" class="Input" id="shenhe" value="1" <%if hrs("shenhe")<>"" then%>checked<%end if%>></td>
</tr>
<tr>
<td class="td1"> </td>
<td class="td2"><input name="Submit" type="submit" class="submit1" value="提交"> <input name="Submit2" type="reset" class="submit1" value="重置"></td>
</tr>
</table>
</form>
<%end if
hrs.close
set hrs=nothing%>
<%
response.End()
end if%>
<%
sql="select * from qwbmbook order by id desc"
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,1,1
if rs.eof and rs.bof then
%>
<div class="divbox1">
暫時無任何單文章 >> <a href="javascript:history.back(1)"><span class="tdf1">返回上一頁</span></a>
</div>
<%else
Dim page,recordsperpage
recordsperpage=15
page=Trim(Request.QueryString("page"))
rs.Pagesize=recordsperpage
If Not IsEmpty(page) Then
If Not IsNumeric(page) Then
page=1
Else
page=Clng(page)
End If
If page>=rs.Pagecount Then
page=rs.Pagecount
Elseif page<=0 Then
page=1
Else
rs.AbsolutePage=page
End If
Else
page=1
End If
rs.AbsolutePage=page
%>
<div class="divm"><strong>共 <font style="color:red;font-size:16px;"><b><%=rs.Recordcount%></b></font> 條留言</strong>
<div class="divml"></div><div class="divmr">留言管理頁面</div>
</div>
<form name="form" method="Post" action="?action=deldel" onSubmit="return ConfirmDel();">
<table cellpadding="0" class="table2">
<tr>
<td class="toptd1" width="36">選擇</td>
<td class="toptd1" width="42">ID</td>
<td class="toptd1" width="37">性別</td>
<td width="214" class="toptd1">留言作者</td>
<td width="214" class="toptd1">留言時間</td>
<td width="53" class="toptd1">預覽</td>
<td width="101" class="toptd1">管理</td>
</tr>
<%Do While rs.Eof=False and recordsperpage>0%>
<tr class="tr1" onMouseOver="this.className='tr2';" onMouseOut="this.className='tr1';">
<td class="td7" width="36"><input onClick="Checked(form)" type="checkbox" name="adid" value='<%=cstr(rs("ID"))%>' /></td>
<td class="td8" width="42"><%=rs("id")%></td>
<td class="td7" width="37"><%if rs("xinb")="w" then
response.write "男"
elseif rs("xinb")="m" then
response.write "女"
end if%></td>
<td class="td8"><%=rs("name")%></td>
<td class="td8"><%=rs("liuyantime")%></td>
<td class="td7"><a href="javascript:newsShowHide('news<%=rs("id")%>');">預覽</A></td>
<td class="td7">
<a href="?action=shen&shenhe=<%=rs("shenhe")%>&id=<%=rs("id")%>">
<%if rs("shenhe")=1 then
response.write "<span class='sh2'>審核</span>"
else
response.write "<span class='sh1'>未審</span>"
end if%></a>
<a href="?action=hui&id=<%=rs("id")%>">
<%if rs("hui")<>"" then
response.write "<span class='zd2'>回復</span>"
else
response.write "<span class='zd1'>未回</span>"
end if%></a>
<a href="?action=del&id=<%=rs("id")%>" onclick='return confirm("真的要刪除嗎?刪除之后將無法恢復\n\n當前作者:<%=rs("name")%>");'>刪除</a></td>
</tr>
<tr id="news<%=rs("id")%>" style="display:none;">
<td colspan="7" class="td11">
<table class="table3" cellpadding="0">
<tr>
<td width="12%" class="td9">姓名:</td>
<td width="74%" class="td10"><%=rs("name")%></td>
<td width="14%" class="td10"><a onClick="newsShowHide('news<%=rs("id")%>')" href="#">關閉</a></td>
</tr>
<tr>
<td class="td9">來自:</td>
<td class="td10"><%=rs("laizi")%></td>
<td rowspan="5" align="center" valign="middle" class="td10"><img src="../images/tu/<%=rs("toux")%>" alt="<%=rs("name")%>" width="90" height="90" /></td>
</tr>
<tr>
<td class="td9">Email:</td>
<td class="td10"><a target="_blank" href="mailto:<%=rs("email")%>"><%=rs("email")%></a></td>
</tr>
<tr>
<td class="td9">QQ:</td>
<td class="td10"><a href="tencent://message/?uin=<%=rs("qicq")%>&Site=客服 1 號&Menu=yes"><img border="0" SRC='http://wpa.qq.com/pa?p=1:<%=rs("qicq")%>:10' alt="點擊這里給我發消息"><%=rs("qicq")%></a></td>
</tr>
<tr>
<td class="td9">主頁:</td>
<td class="td10"><a href="<%=rs("web")%>" target="_blank"><%=rs("web")%></a></td>
</tr>
<tr>
<td class="td9">留言內容:</td>
<td class="td10"><%=rs("liuyan")%></td>
</tr>
<tr>
<td class="td9">留言時間:</td>
<td colspan="2" class="td10"><%=rs("liuyantime")%></td>
</tr>
<tr>
<td class="td9">回復內容:</td>
<td colspan="2" class="td10"><%=rs("hui")%></td>
</tr>
<tr>
<td class="td9">回復時間:</td>
<td colspan="2" class="td10"><%=rs("huitime")%></td>
</tr>
<tr>
<td class="td9">審核:</td>
<td colspan="2" class="td10"><%if rs("hui")<>"" then
response.write "<span class='zd2'>回復</span>"
else
response.write "<span class='zd1'>未回</span>"
end if%></td>
</tr>
</table>
</td>
</tr><% recordsperpage=recordsperpage-1'
rs.MoveNext
Loop%>
<tr class="toptd2">
<td class="td7"><input name="chkAll" type="checkbox" id="chkAll" onClick="CheckAll(this.form)" value="checkbox" /></td>
<td colspan="3" class="td12">
<label for="chkAll"><span class="cheack1">全部選擇</span></label>---
<span class="cheack2" onClick="allobject('您至少選擇 1 條要刪除的信息!','確定要全部刪除當前選擇的信息嗎?\n\n此操作確認后不可以再恢復!','?asp=alldel')">全部刪除</span>
<span class="cheack3" onClick="allobject('您至少選擇 1 條要審核的信息!','確定要審核當前選擇的信息嗎?\n\n此操作確認后不可以再恢復!','?asp=allysh')">全部審核</span>
<span class="cheack4" onClick="allobject('您至少選擇 1 條要打算不審核的信息!','確定要不審核當前選擇的信息嗎?\n\n此操作確認后不可以再恢復!','?asp=allnsh')">全部不審核</span> </td>
<td colspan="3" class="td13"> </td>
</tr>
</table>
<table cellspacing="1" cellpadding="0" class="page">
<tr class="pagetr">
<td class="pagetd1"><%If page<=1 Then %>
[首頁][上一頁]
<%Else%>
<a href="<%=filepath%>?page=<%=1%>">[首頁]</a>
<a href="<%=filepath%>?page=<%=page-1%>">[上一頁]</a>
<%End If%>
<%If page>=rs.Pagecount Then%>
[下一頁][尾頁]
<%Else%>
<a href="<%=filepath%>?page=<%=page+1%>">[下一頁]</a>
<a href="<%=filepath%>?page=<%=rs.Pagecount%>">[尾頁]</a>
<%End If%>
</td>
<td class="pagetd2">[頁次:<font color="red"><b><%=page%></b></font>/<%=rs.Pagecount%>頁][共<font color="red"><b><%=rs.Recordcount%></b></font>篇 <font color="red"><b><%=rs.Pagesize%></b></font>篇/每頁] </td>
<td class="pagetd3">
<form method="get">
<select name="page" class="buttonstyle" onChange="jump_page(this.value)">
<%
For i = 1 To rs.Pagecount
If i=page Then
Response.Write"<option selected value="&i&">"&"第"&i&"頁"&"</option>"
Else
Response.Write"<option value="&i&">"&"第"&i&"頁"&"</option>"
End If
Next
%>
</select>
</form></td>
</tr>
</table>
<%
rs.close
set rs=nothing%>
<%
if request("action")="deldel" then
dim dde
dde=Request("AllID")
if (dde = "") then
Response.Write "<script>window.alert('請選擇要刪除的條目!!!!');window.location='qwbm_book.asp';</script>"
Response.End
else
dddSQL="Delete * from [book] where id in ("&dde&")"
conn.Execute (dddSQL)
response.redirect ThisFileName&"?Result=批量刪除信息成功!"
end if
end if%>
<%
end if
conn.close
set conn=nothing
%>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -