index.asp
来自「全球商务网站系统介绍 GLOBALEC.COM.CN[生成HTML版] 」· ASP 代码 · 共 398 行 · 第 1/2 页
ASP
398 行
if typeid>"" then sql=sql&" and trustadv.type='"&typeid&"'"
sql=sql&" order by trustadv.id desc"
'response.write sql
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
msg_per_page=5 '定义每页显示记录条数
rs.pagesize=msg_per_page '定义分页记录集每页显示记录数
if not (rs.eof and rs.bof) then
totalrec=RS.RecordCount'总记录条数
if rs.recordcount mod msg_per_page=0 then'计算总页数,recordcount:数据的总记录数
n=rs.recordcount\msg_per_page'n:总页数
else
n=rs.recordcount\msg_per_page+1
end if
currentpage=request("page")'currentpage:当前页
If currentpage <> "" then
currentpage = cint(currentpage)
if currentpage < 1 then
currentpage = 1
end if
if err.number <> 0 then '错误处理
err.clear
currentpage=1
end if
else
currentpage=1
End if
if currentpage*msg_per_page > totalrec and not((currentpage-1)*msg_per_page < totalrec)then
currentPage=1
end if
rs.absolutepage=currentpage'absolutepage:设置指针指向某页开头
rowcount=rs.pagesize'pagesize:设置每一页的数据记录数
end if
%>
<table width="578" border="0" cellspacing="0" cellpadding="0">
<tr>
<TD class=M height=40> <span style="color: #FF0000">以下是您收到的评价相关信息:</span></TD>
</tr>
</table>
<table width="578" border="0" cellpadding="0" cellspacing="0" bgcolor="#F1F7FA">
<tr><td><a href="index.asp"><img src="../images/av_remark_list_head1.gif" width="200" height="32" border="0"></a></td>
<td><a href="indexto.asp"><img src="../images/av_remark_list_head11.gif" width="378" height="32" border="0"></a></td>
</tr>
<tr>
<td height="30" colspan="2" style='border-left:#CAE0EB 1 solid;border-right:#CAE0EB 1 solid;border-bottom:#CAE0EB 1 solid'> <img src="../images/classpic.gif" width="6" height="12" align="baseline">
<b>共获得
<a href="index.asp" style="color: #FF0000"><%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&""
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font>条"
totle.close
set totle=nothing
%></a>
评价 好评
<a href="index.asp?typeid=好评" style="color: #FF0000"><%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&" and type='好评'"
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font>条"
totle.close
set totle=nothing
%></a></strong></a>
( <%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&" and type='好评' and pass=1"
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font> 条"
totle.close
set totle=nothing
%>已加分) 建议
<a href="index.asp?typeid=建议" style="color: #FF0000"><%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&" and type='建议'"
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font>条"
totle.close
set totle=nothing
%></a> 批评
<a href="index.asp?typeid=批评" style="color: #FF0000"><%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&" and type='批评'"
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font>条"
totle.close
set totle=nothing
%></a></b>
(<%
sql="select count(id) from trustadv where trustadv.bprid="&session("id")&" and type='批评' and pass=1"
set totle=conn.execute(sql)
totle=totle(0)
response.write"<font color='#FF0000'>"&totle&"</font> 条"
totle.close
set totle=nothing
%>已减分)
</td>
</tr>
</table>
<%if rs.eof then
response.write"<font class=L color=silver><br><br>目前尚未有其他会员对您作出任何评价!<br><br></font>"
else%> <br> <TABLE style="WORD-BREAK: break-all" cellSpacing=0
cellPadding=0 width="578" border=0>
<%do while not rs.eof and rowcount > 0%>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=1 cellPadding=5 width="100%"
align=center bgColor=#cae0eb border=0>
<TBODY>
<TR>
<TD class=C width=250
bgColor=#ffffe1> 评价人:<img src="../../images/trust.gif" width="22" height="14" align="absmiddle"><a href="mailto:<%=rs("email")%>"><%=rs("name")%></a></TD>
<TD class=c align=left
bgColor=#ffffe1>商贸通指数:<FONT
color=red><B><%=rs("trust_score")%></B></FONT></TD>
<TD class=c align=middle
bgColor=#ffffe1>身份:<FONT
color=red><B><%=rs("role")%></B></FONT></TD></TR>
<TR>
<TD class=c bgColor=#ffffe1> <B>评价性质:</B> <span style="font-weight: bold; color: #006600;"><%=rs("type")%></span>
</TD>
<TD colspan="2" bgColor=#ffffe1 class=c align=left>评价时间:(<%=FormatDate(rs("dateandtime"),1)%>)</TD>
</TR></TBODY></TABLE></TD></TR>
<TR>
<TD>
<TABLE width="100%" border=0
align=center cellPadding=5 cellSpacing=0 bgcolor="#F1F7FA">
<TBODY>
<TR vAlign=top>
<TD class=c
width="27%"> <B>评价内容:</B></TD>
<TD
class=sg><%=rs("content")%>
<BR><BR>
</TD></TR></TBODY></TABLE></TD></TR>
<TR>
<TD bgcolor="#FFFFFF"> </TD>
</TR>
</TBODY>
<%
rowcount=rowcount-1
rs.movenext
loop
%></TABLE>
<br>
<TABLE width="578" border="1" cellpadding="4" cellspacing="0" bordercolor="#111111" bordercolorlight="#FCDFB4" bordercolordark="#FCDFB4" style="border-collapse: collapse">
<TR height=25 bgcolor="#FCDFB4"> <td bgcolor="#FEF8E2" align="center"><%call listPages()%></td>
</tr></table>
<BR><BR>
<%
sub listPages()
if not (rs.eof and rs.bof) then
gopage=currentpage
totalpage=n
blockPage=Int((gopage-1)/10)*10+1
if blockPage = 1 Then
Response.Write "<span disabled>【←前10页</span> "
Else
Response.Write("<span disabled>【</span><a href=index.asp?page="&blockPage-10&">←前10页</a> ")
End If
i=1
Do Until i > 10 or blockPage > n
If blockPage=int(gopage) Then
Response.Write("<font color=#FF0000>[<b>"&blockPage&"</b>]</font>")
Else
Response.Write("<a href=index.asp?page="&blockPage&">["&blockPage&"]</a>")
End If
blockPage=blockPage+1
i = i + 1
Loop
if blockPage > totalpage Then
Response.Write " <span disabled>后10页→】"
Else
Response.Write(" <a href=index.asp?page="&blockPage&">后10页→</a><span disabled>】")
End If
Response.Write(" 共"&n&"页 每页"&msg_per_page&"条记录 共"&totalrec&"条记录")
end if
end sub
%>
<%end if%>
<BR></TD></TR></TBODY></TABLE>
</TABLE>
</tr>
</table>
<IMG
height=10 src="../images/bottom.gif" width=778><BR>
<!--#include file="../end.asp"-->
<%
rs.close
set rs=nothing
conn.close
set conn=nothing
%>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?