📄 index.asp
字号:
<%
if application("TOT_Cache")=1 then
application.Contents.RemoveAll()
application("TOT_Cache")=0
end if
%>
<!--#include file="tot_conn.asp" -->
<!--#include file="ubbcode.asp" -->
<%
if(application("TOT_CloseBook")=1) then
response.Write("<script>alert('留言板暂时关闭,请稍后访问\n\n感谢您对我们的支持!');</script>")
response.end()
end if
dim BeginTime,page,recpage,totalpage
BeginTime=Timer
if not isempty(request("page")) then
currentpage=Clng(request("page"))
else currentpage=1
end if
recpage=Cint(application("TOT_PageSize"))
%>
<html>
<head>
<title><%=application("TOT_Title")%>留言板</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
body {
background-image: url(images/webbg.gif);
background-position:center 50%;
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
.style1 {
color: #FFFFFF;
font-weight: bold;
}
.style2 {color: #FFFFFF}
-->
</style></head>
<script language="javascript">
function goto(frm)
{
var gourl ="index.asp?";
gourl += "page=" + (frm.page.value);
var hid=parseInt(frm.hid.value);
if(parseInt(frm.page.value)>hid||frm.page.value<=0){
alert("错误!请确定你输入的数字在1-"+hid+"之间");
return false;
}
window.location.href(gourl);
}</script>
<%if(isAdmin) then%>
<script language="JavaScript" type="text/JavaScript">
function ConfirmDel()
{
if(confirm("确认删除这个留言吗?并且不能恢复!"))
return true;
else
return false;
}
</script>
<%end if%>
<body>
<%=application("BBS_Head")%>
<table width="750" height="40" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td width="228"><div align="center">-=>您现在的位置:<a href="#">首页</a>-><a href="#">留言</a></div></td>
<td width="522" style="padding:0 60px 0 0; "><div align="right"><%if(isAdmin) then%><a href="edit.asp?act=config"><img src="images/config.jpg" width="71" height="26" border="0"></a> <a href="edit.asp?act=logout"><img src="images/logout.jpg" width="71" height="26" border="0"></a><%end if%> <a href="admin_login.asp"><img src="images/LoginA.gif" width="71" height="26" border="0"></a> <a href="guest_add.asp"><img src="images/LoginB.gif" width="71" height="26" border="0"></a> <a href="index.asp"><img src="images/LoginC.gif" width="71" height="26" border="0"></a></div></td>
</tr>
</table>
<table width="750" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="12"><div align="left"><img src="images/tot_a.gif" width="12" height="16"></div></td>
<td width="726" background="images/tot_b.gif"> </td>
<td width="12"><div align="right"><img src="images/tot_c.gif" width="12" height="16"></div></td>
</tr>
<tr>
<td height="25" colspan="3" background="images/bg.gif"> <span class="style1">-=>站点公告</span></td>
</tr>
<tr>
<td colspan="3"><table width=750
border=1 align="center" cellPadding="0" cellSpacing="0" borderColor="#e6e6e6" bgcolor="#FFFFFF">
<tr>
<td align=middle width=30 height=30><div align="center"><img src="images/b.jpg" width="16" height="18"></div></td>
<td width=470><div align="center"><%=application("TOT_Content")%></div></td>
<td width=250> <font color=#e08700>■</font> 今日留言: <%=application("TOT_TodayAddNum")%> <font color=#e08700>■</font> 留言总数: <%=application("TOT_TotalAddNum")%></td>
</tr>
</table></td>
</tr>
</table>
<TABLE height=2 cellSpacing=0 cellPadding=0 width=750 align=center border=0>
<TBODY>
<TR>
<TD width=12><IMG src="images/tot_aa.gif" width="12" height="12"></TD>
<TD width=726 background=images/tot_bb.gif></TD>
<TD width=12><IMG src="images/tot_cc.gif" width="12" height="12"></TD>
</TR>
</TBODY>
</TABLE><br>
<!-- 开始按行循环----------------------->
<%
totalpage=int((application("TOT_TotalAddNum")+recpage-1)/recpage)
function GetBooList
dim listStr
listStr=""
set rs=server.createobject("adodb.recordset")
if(currentpage=1) then
if(isAdmin) then
sql="select top "&recpage&" * from TOT_GuestBook order by Top_Sort desc,DateTime desc"
else
sql="select top "&recpage&" * from TOT_GuestBook where CanSee=0 order by Top_Sort desc,DateTime desc"
end if
else
if(isAdmin) then
sql="select top "&recpage&" * from TOT_GuestBook where id not in (select top "&(recpage*(currentpage-1))&" id from TOT_GuestBook order by id desc) order by id desc "
else
sql="select top "&recpage&" * from TOT_GuestBook where id not in (select top "&(recpage*(currentpage-1))&" id from TOT_GuestBook where CanSee=0 order by id desc) and CanSee=0 order by id desc "
end if
end if
rs.open sql,conn,3,1
i2=0
do while not rs.eof
listStr=listStr&"<TABLE height=2 cellSpacing=0 cellPadding=0 width=750 align=center border=0>"&Chr(13)
listStr=listStr&"<TBODY>"&Chr(13)
listStr=listStr&"<TR>"&Chr(13)
listStr=listStr&"<TD width=12><IMG src=""images/tot_a.gif"" width=""12"" height=""12""></TD>"&Chr(13)
listStr=listStr&"<TD width=726 background=""images/tot_b.gif""></TD>"&Chr(13)
listStr=listStr&"<TD width=12><IMG src=""images/tot_c.gif"" width=""12"" height=""12""></TD>"&Chr(13)
listStr=listStr&"</TR>"&Chr(13)
listStr=listStr&"</TBODY>"&Chr(13)
listStr=listStr&"</TABLE>"&Chr(13)
listStr=listStr&"<table width=""750"" border=""0"" align=""center"" cellpadding=""0"" cellspacing=""0"">"&Chr(13)
listStr=listStr&"<tr>"&Chr(13)
listStr=listStr&"<td height=""25"" colspan=""3"" background=""images/bg.gif""> <span class=""style1"">-=>标题:"&rs("title")&"</span>"&Chr(13)
listStr=listStr&"<span class=""style2""><FONT color=#ffffff>"&Chr(13)
if(isAdmin) then
listStr=listStr&"--------------------『Ip:"&rs("ip")&"』__"&rs("DateTime")&Chr(13)
end if
listStr=listStr&"</FONT></span></td>"&Chr(13)
listStr=listStr&"</tr>"&Chr(13)
listStr=listStr&"<tr>"&Chr(13)
listStr=listStr&"<td colspan=""3"" bgcolor=""#FFFFFF""><table width=""100%"" border=""1"" cellpadding=""0"" cellspacing=""0"" bordercolor=""#e6e6e6"" style=""TABLE-LAYOUT: fixed; "">"&Chr(13)
listStr=listStr&"<tr>"&Chr(13)
listStr=listStr&"<td width=""21%""><div align=""center"">"&rs("name")&"</div></td>"&Chr(13)
listStr=listStr&"<td width=""79%"">"&Chr(13)
listStr=listStr&"<a target=""blank"" href=""http://wpa.qq.com/msgrd?V=1&Uin="&rs("qq")&"&Site=淘特网&Menu=yes""> <img SRC=""http://wpa.qq.com/pa?p=1:32322:9"" alt='点击这里给我发消息' width=""51"" height=""16"" border='0' Rsbook(5) &></a> "&Chr(13)
if(isAdmin) then
listStr=listStr&"<A href=""edit.asp?act=reply&cd="&rs("cd")&"""><IMG src=""images/Replies.gif"" width=""42"" height=""16"" border=0></A> "&Chr(13)
end if
listStr=listStr&"<A href="""&rs("web")&""" target=_blank><IMG src=""images/web.gif"" width=""42"" height=""16"" border=0></A> "&Chr(13)
listStr=listStr&"<a href=""#"" title="""&rs("WhereIs")&"""><IMG src=""images/come.gif"" alt="""&rs("WhereIs")&""" width=""42"" height=""16"" border=0></a> "&Chr(13)
listStr=listStr&"<a href=""mailto:"&rs("email")&""" target=""_blank""><IMG src=""images/email.gif"" alt=adsf@11.com width=""42"" height=""16"" border=0></a> "&Chr(13)
listStr=listStr&"<A href=""edit.asp?act=editor&cd="&rs("cd")&"""><IMG src=""images/bj.gif"" width=""42"" height=""16"" border=0></A> "&Chr(13)
if(isAdmin) then
listStr=listStr&"<A href=""edit.asp?act=del&cd="&rs("cd")&""" onClick=""return ConfirmDel()""><IMG src=""images/delete.gif"" width=""42"" height=""15"" border=0></A> "&Chr(13)
end if
if(isAdmin) then
listStr=listStr&"<A href=""edit.asp?act=top&cd="&rs("cd")&""">"&Chr(13)
else
listStr=listStr&"<A href=""#"">"&Chr(13)
end if
listStr=listStr&"<IMG src=""images/top.gif"" width=""35"" height=""15"" border=0></A>"&rs("Top_Sort")&Chr(13)
listStr=listStr&"</td>"&Chr(13)
listStr=listStr&"</tr>"&Chr(13)
listStr=listStr&"<tr>"&Chr(13)
listStr=listStr&"<td style=""padding:5px; ""><div align=""center""><img src=""images/img/"&rs("Image")&""" width=""90"" height=""90""></div></td>"&Chr(13)
listStr=listStr&"<td valign=""top"" style=""padding:10px; line-height:20px;WORD-WRAP: break-word"" > "&Gl(ubbcode(dvHTMLEncode(rs("content"))))&"<br>"&Chr(13)
if(len(rs("Replies"))>0) then
listStr=listStr&"<HR align=right width=""50%"" color=#eaeaea>"&Chr(13)
listStr=listStr&"<TABLE height=52 cellSpacing=0 cellPadding=0 width=392 align=right border=0>"&Chr(13)
listStr=listStr&"<TBODY>"&Chr(13)
listStr=listStr&" <TR>"&Chr(13)
listStr=listStr&" <TD colSpan=3 height=8><IMG height=8 alt="""" src=""images/Replies_01.gif"" width=389></TD>"&Chr(13)
listStr=listStr&" </TR>"&Chr(13)
listStr=listStr&" <TR>"&Chr(13)
listStr=listStr&" <TD width=10 background=""images/Replies_02.gif"" height=13>"&Chr(13)
listStr=listStr&" <TABLE cellSpacing=0 cellPadding=0 width=10 border=0>"&Chr(13)
listStr=listStr&" <TBODY>"&Chr(13)
listStr=listStr&" <TR>"&Chr(13)
listStr=listStr&" <TD> </TD>"&Chr(13)
listStr=listStr&" </TR>"&Chr(13)
listStr=listStr&" </TBODY>"&Chr(13)
listStr=listStr&" </TABLE></TD>"&Chr(13)
listStr=listStr&" <TD width=370>"&Chr(13)
listStr=listStr&" <TABLE style=""TABLE-LAYOUT: fixed; FILTER: glow(color=FBB378); WORD-BREAK: break-all; LINE-HEIGHT: 20px"" cellSpacing=0 cellPadding=0 width=370 border=0>"&Chr(13)
listStr=listStr&" <TBODY>"&Chr(13)
listStr=listStr&" <TR>"&Chr(13)
listStr=listStr&" <TD>"&rs("Replies")&"</TD>"&Chr(13)
listStr=listStr&" </TR>"&Chr(13)
listStr=listStr&" </TBODY>"&Chr(13)
listStr=listStr&" </TABLE></TD>"&Chr(13)
listStr=listStr&" <TD width=12 background=""images/Replies_04.gif""> </TD>"&Chr(13)
listStr=listStr&" </TR>"&Chr(13)
listStr=listStr&" <TR>"&Chr(13)
listStr=listStr&" <TD colSpan=3 height=31><IMG height=31 alt="""" src=""images/Replies_05.gif"" width=389></TD>"&Chr(13)
listStr=listStr&" </TR>"&Chr(13)
listStr=listStr&" </TBODY>"&Chr(13)
listStr=listStr&"</TABLE>"&Chr(13)
end if
listStr=listStr&"</td>"&Chr(13)
listStr=listStr&"</tr>"&Chr(13)
listStr=listStr&"</table></td>"&Chr(13)
listStr=listStr&"</tr>"&Chr(13)
listStr=listStr&"</table>"&Chr(13)
listStr=listStr&"<TABLE height=2 cellSpacing=0 cellPadding=0 width=750 align=center border=0>"&Chr(13)
listStr=listStr&"<TBODY>"&Chr(13)
listStr=listStr&"<TR>"&Chr(13)
listStr=listStr&"<TD width=12><IMG src=""images/tot_aa.gif"" width=""12"" height=""12""></TD>"&Chr(13)
listStr=listStr&"<TD width=726 background=images/tot_bb.gif></TD>"&Chr(13)
listStr=listStr&"<TD width=12><IMG src=""images/tot_cc.gif"" width=""12"" height=""12""></TD>"&Chr(13)
listStr=listStr&"</TR>"&Chr(13)
listStr=listStr&"</TBODY>"&Chr(13)
listStr=listStr&"</TABLE><br>"&Chr(13)
i2=i2+1
if i2>=recpage then
exit do
end if
rs.movenext
loop
rs.close
set rs=nothing
GetBooList=listStr
end function
if(isAdmin) then
response.Write(GetBooList())
else
if(application("TOT_BBS_Page_"¤tpage))="" then
application.Lock()
application("TOT_BBS_Page_"¤tpage)=GetBooList()
application.UnLock()
end if
response.Write(application("TOT_BBS_Page_"¤tpage))
end if
%>
<table width="750" height="22" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td><div align="center">
<form name="form1" method="post" action="" style="margin:0 0 0 0">
<%
n=currentpage+1
p=currentpage-1
if p>0then
response.write("["&"<a href='index.asp?page="&cstr(p)&"'>上一页</a>] ")
else
response.write("上一页 ")
end if
if (n-1)*recpage>=Clng(application("TOT_TotalAddNum")) then
response.write("下一页" )
else
response.Write("["&"<a href='index.asp?page="&cstr(n)&"'>下一页</a>]")
end if
response.write(" 共"&application("TOT_TotalAddNum")&"条 ")
response.Write(" 共"&totalpage&"页 ")
response.Write(" 第"¤tpage&"页 ")
%>
<input type="hidden" name="hid" value="<%=totalpage%>">
跳至
<input name="page" type="text" size="5" onChange="goto(this.form)" style="border:1px solid #000000;height:18px ">
页
<input type="button" name="Button22" value="Go->" style="font-size:12px ;border:1px solid #000000;height:18px ">
</form>
<%=CStr(FormatNumber((Timer-BeginTime)*1000,2))& "毫秒"%>
</div></td>
</tr>
</table>
<%=application("BBS_Root")%>
</body>
</html>
<%call connclose()%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -