manage_gbook.asp

来自「烈火之家整站程序 本程序集商业娱乐一体,本来是给自己用的但是我的国外空间支持不够」· ASP 代码 · 共 111 行

ASP
111
字号
<!--#include file="admin.asp"-->
<!--#include file="conn.asp"-->
<html>
<head>
<META content="text/html; charset=gb2312" http-equiv=Content-Type>
<LINK href="../images/css.css" rel=stylesheet type=text/css>
<title></title>
</head>
<!-- #include file="../Inc/Head.asp" -->
<body topmargin=0>
<%
sql2="select * from book  order by ID desc"        
set gbook=server.createobject("adodb.recordset")        
gbook.open sql2,conn,1,1
if gbook.eof and gbook.bof then
response.write "<center><a href=add.asp>现在还没有人留言!我要第一个留言.</a></center>"
else
gbook.pagesize=rs("count")
gbook.absolutepage=1
if request("page")<>"" then gbook.absolutepage=request("page")
rowcount=gbook.pagesize
total=gbook.recordcount
do while not gbook.eof and rowcount>0
if request("page")<>"" then
t=rowcount-(gbook.pagesize*gbook.pagecount-total)+(gbook.pagecount-request("page"))*gbook.pagesize
else t=rowcount-(gbook.pagesize*gbook.pagecount-total)+(gbook.pagecount-1)*gbook.pagesize
end if
%>
<table cellspacing="1" cellpadding="4" width="98%" border="0" class="a2" align="center" height="134" bgcolor="#FFFFFF">          
          <tbody>         
          <tr class="a1">         
            <td height=25 bgcolor="#FFFFFF" width="80%" colspan="2"> 第 <font color=red><%=t%></font> 条留言  留言者:<font color=red><%=gbook("昵称")%></font>  发表于:<%=gbook("时间")%>     
            </td>        
          </tr>     
          <tr>      
            <td bgcolor="#FFFFFF" align=center height=50> <b>留言内容:</b></td>     
            <td bgcolor="#FFFFFF" rowspan=2 class=365ye style="word-break:break-all"><div style="line-height:150%"> 
<%if gbook("image")<>"" then%><b>[悄悄话]</b><%=left(gbook("内容"),1000)%><%else%><%=left(gbook("内容"),1000)%><%end if%>
            </td>
          </tr>     
          <tr>      
            <td width="130" height="25"  class="a3"> <img height=16 src="../images/homepage.gif"        
            width=16><a href="<%=gbook("home")%>" target=_blank        
            title=访问<%=gbook("昵称")%>的主页> 我的主页</a></td>    
          </tr>     
          <tr>      
            <td width="130" height="25" bgcolor="#FFFFFF" > <img height=16 src="../images/email.gif"        
            width=16><a href="mailto:<%=gbook("email")%>"        
            title=写信给我> 写信给我</a></td>                                  
            <td width="550"  class="a3" style="word-break:break-all"><p style="line-height: 150%">〖回复〗 
          <% if not gbook("回复")="" then %>
          <%=gbook("回时")%><font color="#CC3300"><%=gbook("回复")%></font> 
          <%else%>
          <font color="#FF0000">管理员尚未回复本留言 !</font> 
          <%end if%>
        </p></td>     
          </tr>     
          <tr>      
            <td width="130" height="25" class="a3"> <img height=16 src="../images/oicq.gif"        
            width=16> <%=gbook("OICQ")%></td>             
            <td width="550" bgcolor="#FFFFFF">&nbsp;<%=gbook("ip")%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;                                          
                  [ <a href="addbook1.asp"><font color="#000080">签写留言</font></a> ] [                                             
                  <a href="replay_gbook.asp?id=<%=gbook("ID")%>">   
                  回复留言                                       
                  </a>   
                  ] [                                              
                  <a href="del_gbook.asp?id=<%=gbook("ID")%>">    
                  删除留言                                         
                  </a>    
                  ] </td>              
          </tr>     
          </tbody>       
  </table>     
  <p> 
    <%     
gbook.movenext     
rowcount=rowcount-1
loop     
%>
  </p>
  第 <%
  if gbook.pagecount>0 then
  for i=1 to gbook.pagecount
  response.write "<a href=index.asp?page="& i &">[" & i & "]</a>"
  next
  end if%> 页    
</CENTER>     
<p><br><br>
</center>
</BODY><%  
gbook.close     
set gbook=nothing    
rs.close    
set rs=nothing   
end if 
conn.close    
set conn=nothing  
%>












⌨️ 快捷键说明

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