📄 sysbook.asp
字号:
}
}
function NewsOrProductObj(Obj,Index,Selected)
{
this.Obj=Obj;
this.Index=Index;
this.Selected=Selected;
}
function EditContent()
{
var SelectedContent='',SelectContentObj=null;
for (i=0;i<ListObjArray.length;i++)
{
if (ListObjArray[i].Selected==true)
{
if (ListObjArray[i].Obj.ContentID!=null)
{
if (SelectedContent=='') SelectedContent=ListObjArray[i].Obj.ContentID;
else SelectedContent=SelectedContent+'***'+ListObjArray[i].Obj.ContentID;
}
SelectContentObj=ListObjArray[i].Obj;
}
}
if (SelectedContent!='')
{
if (SelectedContent.indexOf('***')==-1)
{
if (SelectContentObj.ContentTypeStr!=null)
{
location='SysBookModify.asp?ID='+SelectedContent;
}
}
else alert('一次只能够修改一条帖子');
}
else alert('请选择要修改的帖子');
}
function ReadBook()
{
var SelectedContent='',SelectContentObj=null;
for (i=0;i<ListObjArray.length;i++)
{
if (ListObjArray[i].Selected==true)
{
if (ListObjArray[i].Obj.ContentID!=null)
{
if (SelectedContent=='') SelectedContent=ListObjArray[i].Obj.ContentID;
else SelectedContent=SelectedContent+'***'+ListObjArray[i].Obj.ContentID;
}
SelectContentObj=ListObjArray[i].Obj;
}
}
if (SelectedContent!='')
{
if (SelectedContent.indexOf('***')==-1)
{
if (SelectContentObj.ContentTypeStr!=null)
{
location='SysBookRead.asp?ID='+SelectedContent;
}
}
else alert('一次只能够查看一条帖子');
}
else alert('请选择要查看的帖子');
}
function DelContent()
{
var SelectedContent='',SelectContentObj=null;
for (i=0;i<ListObjArray.length;i++)
{
if (ListObjArray[i].Selected==true)
{
if (ListObjArray[i].Obj.ContentID!=null)
{
if (SelectedContent=='') SelectedContent=ListObjArray[i].Obj.ContentID;
else SelectedContent=SelectedContent+','+ListObjArray[i].Obj.ContentID;
}
SelectContentObj=ListObjArray[i].Obj;
}
}
if (SelectedContent!='')
{
if (SelectContentObj.ContentTypeStr!=null)
{
location='SysBookDelSave.asp?Action=Del&GID='+SelectedContent;
}
}
else alert('请选择要删除的帖子');
}
function ShowAddMenu()
{
var MenuObj=document.all.AddContentMenu;
var el=event.srcElement;
MenuObj.style.display='';
MenuObj.style.posLeft=el.offsetLeft;
MenuObj.style.posTop=el.offsetHeight;
MenuObj.className="menushow";
MenuObj.setCapture();
}
function MouseOverRightMenu()
{
var el=event.srcElement;
if (el.tagName!='TD') return;
if (el.ExeFunction==null) return;
if (el.style.backgroundColor=="highlight") {el.style.backgroundColor='';el.style.color='black';}
else {el.style.backgroundColor="highlight";el.style.color='white';}
}
function ClickMenu(MenuObj)
{
var CurrObj=null;
var IMGObj=document.body.getElementsByTagName('IMG');
for (var i=0;i<IMGObj.length;i++)
{
CurrObj=IMGObj(i);
if (CurrObj.className=='BtnMouseOver') CurrObj.className='';
}
var el=event.srcElement;
MenuObj.releaseCapture();
MenuObj.className="menu";
for (var i=0;i<MenuObj.children.length;i++)
{
var CurrObj=MenuObj.children(i);
for (var j=0;j<CurrObj.children.length;j++)
{
if (CurrObj.children(j).className=='MenuShow') {CurrObj.children(j).className='Menu';}
}
}
if (el.ExeFunction!=null) eval(el.ExeFunction);
}
function ChangePageNO(NO,SearchStr)
{
var LocationStr=window.location.href;
var SearchLocation=LocationStr.lastIndexOf(SearchStr);
if (SearchLocation!=-1)
{
var TempSearchLocation=LocationStr.indexOf('&',SearchLocation);
if (TempSearchLocation!=-1)
{
LocationStr=LocationStr.slice(0,SearchLocation)+SearchStr+'='+NO+window.location.href.slice(TempSearchLocation);
}
else LocationStr=LocationStr.slice(0,SearchLocation)+SearchStr+'='+NO;
}
else
{
if (LocationStr.lastIndexOf('?')!=-1) LocationStr=LocationStr+'&'+SearchStr+'='+NO;
else LocationStr=LocationStr+'?'+SearchStr+'='+NO;
}
window.location=LocationStr;
}
function SearchLyPage()
{
SearchPage.style.display='';
}
</script>
<body topmargin="2" leftmargin="2" onclick="ClickBook(event);" onselectstart="return false;">
<table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#999999">
<tr bgcolor="#EEEEEE">
<td height="26" colspan="5" valign="middle">
<table height="22" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width=55 align="center" alt="所有留言" onClick="top.GetEkMainObject().location='SysBook.asp';" onMouseMove="BtnMouseOver(this);" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">所有留言</td>
<td width=2 class="Gray">|</td>
<td width=55 align="center" alt="添加留言" onClick="top.GetEkMainObject().location='SysBookWrite.asp';" onMouseMove="BtnMouseOver(this);//ShowAddMenu();" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">发表留言</td>
<td width=2 class="Gray">|</td>
<td width=65 align="center" alt="已回复留言" onClick="top.GetEkMainObject().location='SysBook.asp?Action=Q';" onMouseMove="BtnMouseOver(this);//ShowAddMenu();" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">已回复留言</td>
<td width=2 class="Gray">|</td>
<td width=65 align="center" alt="未回复留言" onClick="top.GetEkMainObject().location='SysBook.asp?Action=UnQ';" onMouseMove="BtnMouseOver(this);//ShowAddMenu();" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">未回复留言</td>
<td width=2 class="Gray">|</td>
<td width=55 align="center" alt="留言搜索" onClick="SearchLyPage();" onMouseMove="BtnMouseOver(this);//ShowAddMenu();" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">留言搜索</td>
<td width=2 class="Gray">|</td>
<td width=35 align="center" alt="后退" onClick="top.GetEkMainObject().history.back();" onMouseMove="BtnMouseOver(this);" onMouseOut="BtnMouseOver(this);" class="BtnMouseOut">后退</td>
</tr>
</table></td>
</tr>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" height="90%">
<tr>
<td height="2"></td>
</tr>
<tr>
<td valign="top">
<table width="100%" border="0" cellpadding="3" cellspacing="0" bgcolor="#CCCCCC">
<tr bgcolor="#E8E8E8">
<td width="36%" class="ButtonListleft"><div align="center">标题</div></td>
<td width="15%" class="ButtonList"><div align="center">发言人</div></td>
<td width="19%" class="ButtonList"><div align="center">发表时间</div></td>
<td width="17%" class="ButtonList"><div align="center">回复时间</div></td>
</tr>
<%
dim RsCon,strpage,select_count,select_pagecount
strpage=request.querystring("page")
if len(strpage)=0 then
strpage="1"
end if
Dim QS
IF Request("Action")="Q" then
QS = " and isQ=1"
ElseIf Request("Action")="UnQ" then
QS = " and isQ=0"
Else
QS = ""
End if
Dim Ks
If Request("Keyword")<>"" then
Ks = " and Content like '%"& Replace(Request("Keyword"),"'","") &"%' or Title like '%"& Replace(Request("Keyword"),"'","") &"%'"
Else
Ks = ""
End if
Set RsCon = Server.CreateObject (G_FS_RS)
RsCon.Source="select * from FS_GBook where QID=0 "& QS & Ks &" Order by Orders,Qtime desc,Addtime desc"
RsCon.Open RsCon.Source,UserConn,1,1
If RsCon.eof then
RsCon.close
set RsCon=nothing
Response.Write"<TR><TD colspan=""7"" bgcolor=FFFFFF>没有记录。</TD></TR>"
Else
Dim Product_Page_Size,Product_Page_No,Product_Page_Total,Product_Record_All,Product_For_Var
Product_Page_Size = 20
Product_Page_No = Request.Querystring("Product_Page_No")
if Product_Page_No <= 0 or Product_Page_No = "" then Product_Page_No = 1
RsCon.PageSize = Product_Page_Size
Product_Page_Total = RsCon.PageCount
if (Cint(Product_Page_No) > Product_Page_Total) then Product_Page_No = Product_Page_Total
RsCon.AbsolutePage = Product_Page_No
Product_Record_All = RsCon.RecordCount
for Product_For_Var = 1 to RsCon.PageSize
if RsCon.Eof then Exit For
%>
<tr bgcolor="#FFFFFF">
<td nowrap><%If RsCon("Orders")=1 then%>
<img src="../../../<%=UserDir%>/GBook/Images/ztop.gif" alt="固顶帖" width="18" height="15">
<%Else%>
<img src="../../../<%=UserDir%>/GBook/Images/hotfolder.gif" alt="一般帖子" width="18" height="12">
<%End if%>
<span ContentTypeStr="5" AuditTF="" class="TempletItem" ContentID="<% = RsCon("ID") %>" align="center">
<%if len(RsCon("Title"))>18 then
Response.Write left(RsCon("Title"),18)&".."
Else
Response.Write RsCon("Title")
End if
%>
</SPAN></td>
<td align="center"> <%
If RsCon("UserID")=0 then
Response.Write("<font color=#990000>管理员</font>")
Else
Fs_User.ID = CLng(RsCon("UserID"))
If Fs_User.EName<>"" And IsNull(Fs_User.EName)=False then
Response.Write("<a href=../../../"&UserDir&"/ReadUser.Asp?UserName="&Fs_User.EName&">"& Fs_User.EName&"</a>")
Else
Response.Write("用户已被删除")
End if
End If
%> </td>
<td align="center"> <% = RsCon("Addtime")%> </td>
<td align="center"> <font color="#FF0000">
<%
If RsCon("Qtime")=RsCon("Addtime") Or RsCon("Qtime")="" Or RsCon("isQ") =0 then
Response.Write("")
Else
Response.Write RsCon("Qtime")
End if
%>
</font> </td>
</tr>
<%
RsCon.MoveNext
Next
%>
</table>
<%
End if
Function ProductPageStr()
ProductPageStr = "位置:<b>"& Product_Page_No &"</b>/<b>"& Product_Page_Total &"</b> "
if Product_Page_Total = 1 then
ProductPageStr = ProductPageStr & " <img src=""../../images/FirstPage.gif"" border=0 alt=首页> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=""../../images/prePage.gif"" border=0 alt=上一页> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=""../../images/nextPage.gif"" border=0 alt=下一页> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=""../../images/endPage.gif"" border=0 alt=尾页> " & Chr(13) & Chr(10)
else
if cint(Product_Page_No) <> 1 and cint(Product_Page_No) <> Product_Page_Total then
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('1','Products_Page_No');"" style=""cursor:hand;""><img src=""../../images/FirstPage.gif"" border=0 alt=首页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_No - 1 & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/prePage.gif border=0 alt=上一页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_No + 1 & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/nextPage.gif border=0 alt=下一页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_Total & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/endPage.gif border=0 alt=尾页></span> " & Chr(13) & Chr(10)
elseif cint(Product_Page_No) = 1 then
ProductPageStr = ProductPageStr & " <img src=../../images/FirstPage.gif border=0 alt=首页> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=../../images/prePage.gif border=0 alt=上一页> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_No + 1 & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/nextPage.gif border=0 alt=下一页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_Total & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/endpage.gif border=0 alt=尾页></span> " & Chr(13) & Chr(10)
else
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('1','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/FirstPage.gif border=0 alt=首页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <span onclick=""ChangePageNO('" & Product_Page_No - 1 & "','Product_Page_No');"" style=""cursor:hand;""><img src=../../images/prePage.gif border=0 alt=上一页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=../../images/nextPage.gif border=0 alt=下一页></span> " & Chr(13) & Chr(10)
ProductPageStr = ProductPageStr & " <img src=../../images/endpage.gif border=0 alt=尾页> " & Chr(13) & Chr(10)
end if
end if
End Function
%>
<table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#E7E7E7" id="SearchPage" style="display:none;">
<tr bgcolor="#FFFFFF">
<td width="9%"><a href="SysBook.asp">留言搜索</a><a href="SysBook.asp?Action=UnQ"></a></td>
<form name="form1" method="post" action="SysBook.asp">
<td width="91%"> <input name="Keyword" type="text" id="Keyword">
<input type="submit" name="Submit2" value="搜索"> </td>
</form>
</tr>
</table>
</td>
</tr>
</table>
<table width="100%" border="0" cellpadding="5" cellspacing="0">
<tr>
<td align="right" class="ButtonListLeft"><%=ProductPageStr%></td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -