国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學(xué)院 > 開發(fā)設(shè)計(jì) > 正文

用排序串字段實(shí)現(xiàn)樹狀結(jié)構(gòu)(例程——顯示貼子內(nèi)容)

2019-11-18 22:29:56
字體:
供稿:網(wǎng)友
程序:disPRec.asp
功能:顯示貼子具體內(nèi)容

<!-- #include file="lybcon.inc" -->
<%
keyid=request("keyid")
rootid=request("rootid")
pageno=request("pageno")
if rootid=0 then rootid=keyid
set guestconn=Server.CreateObject("ADODB.connection")
guestconn.Open lybstr
set guestrs=server.createobject("ADODB.recordset")
sqlstr="SELECT * FROM guestbook where lybid="&rootid&" or rootid="&rootid
sqlstr=sqlstr&" order by orderstr,lybid desc"
guestrs.open sqlstr,guestconn,1,1
%>
<html>
<head><title>軟件使用留言薄</title>
<style TYPE="text/CSS">
<!--
a {  text-decoration: none}
body {line-height:18px;font-size:9pt;font-family:宋體}
a:hover {color:#FF0000;text-decoration:none}
td {font-family: 宋體; font-size: 9pt;background-color:ECF7FF}
.td1 {font-family: 宋體; font-size: 9pt;background-color:A2C8F2}
.td2 {font-family: 宋體; font-size: 9pt;background-color:E9EDE0}
.small1 {font-family: 宋體; font-size: 9pt;background-color:ffffff;line-height:9pt}
-->
</style>
</head>
<body topmargin=16 background='topbg.gif'>
<form name='index' method='POST' action='index.asp'>
<table width=100% align=center>
  <tr>
   <td align=center style='font-size:16px;background-color:ffffff;color:red' height=35 valign=top>軟件使用
留言薄</td>
   <td align=center colspan=2 style='background-color:ffffff' valign='bottom'>相關(guān)留言共<font style='font-
size:16px;color:red'><% =guestrs.recordcount %></font>條</td>
   <td style='background-color:ffffff' valign=bottom align=center><a href='index.asp?pageno=<% =pageno %>'>
留言列表</a></td>
   <td style='background-color:ffffff' valign=bottom align=center><a href='revert.asp?type=post'>發(fā)貼子
</a></td>
  </tr>
  <tr style="color:red">
   <td align=center class='td1' width=70%>留言標(biāo)題</td>
   <td align=center width=70 class='td1' nowrap><img src='edit.gif'>作  者</td>
   <td align=center width=100 class='td1' nowrap>發(fā)表時(shí)間</td>
   <td align=center width=60 class='td1' nowrap>貼子字?jǐn)?shù)</td>
   <td align=center width=60 class='td1' nowrap>貼子序號</td>
  </tr>
<% do while not guestrs.eof %>
  <tr>
   <td><% if guestrs("rootid")<>0 then response.write(replace(space(len(guestrs("orderstr")))," ","  ")) %
><% if guestrs("lybid")+1=keyid+1 then
    if guestrs("rootid")=0 then
      rootid=guestrs("lybid")
    else
      rootid=guestrs("rootid")
    end if
    lybid=guestrs("lybid")
    guestitle=guestrs("guestitle")
    guestname=guestrs("guestname")
    guestemail=guestrs("guestemail")
    guestcomm=guestrs("guestcomm")
    putdate=guestrs("putdate")
    puttime=guestrs("puttime")
    emailflag=guestrs("emailflag")
%><% =guestrs("guestitle") %><% else %><a href='disprec.asp?keyid=<% =guestrs("lybid") %>&rootid=<%
=guestrs("rootid") %>&pageno=<% =pageno %>'><% =guestrs("guestitle") %></a><% end if %></td>
   <td align=right nowrap><% =guestrs("guestname") %> </td>
   <td nowrap align=center nowrap><% =guestrs("putdate")&" "&guestrs("puttime") %></td>
   <td align=right nowrap><% =len(guestrs("guestcomm")) %> </td>
   <td align=right nowrap><% =guestrs("lybid") %> </td>
  </tr>
<%
guestrs.movenext
loop
guestrs.close
set guestrs=nothing
guestconn.close
set guestconn=nothing
%>
<tr><td height=20 colspan=5 style="background-color:ffffff"></td></tr>
<tr>
<td style="color:red" align=center><% =guestitle %></td>
<td align=right width=70><% =guestname %> </td>
<td width=100><% =putdate&" "&puttime %></td>
<td align=right width=60><% =len(guestcomm) %> </td>
<td align=right width=60><% =lybid %> </td>
</tr>
<tr><td colspan=5 style="background-color:f3F7FF" height=50 valign=top><% =guestcomm %><p align=right><a
href='delrec.asp?type=revert&keyid=<% =keyid %>&pageno=<% =pageno %>'>刪除留言</a>    <a href='revert.asp?
type=revert&keyid=<% =lybid %>&pageno=<% =pageno %>'>回復(fù)作者</a>  </td></tr>
</table>
</form>
</body>
</html>

發(fā)表評論 共有條評論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 临沂市| 仪征市| 同德县| 闽清县| 海晏县| 五峰| 启东市| 台山市| 札达县| 宝丰县| 扶沟县| 慈溪市| 乐业县| 延庆县| 丰都县| 江永县| 平泉县| 大同县| 武城县| 莲花县| 锦州市| 潞城市| 富川| 沅江市| 安化县| 潞城市| 雷波县| 交口县| 嘉荫县| 上思县| 萨嘎县| 磐石市| 江门市| 崇左市| 双桥区| 庆元县| 上林县| 西乌珠穆沁旗| 台安县| 阿勒泰市| 聂荣县|