📄 commentm.asp
字号:
<%@ language="vbscript" %>
<%
dim boardname,id
if isempty(request("boardname")) then
response.write "bordid error"
response.end
else
boardname=request("boardname")
end if
if isempty(request("id")) then
response.write "id error"
response.end
else
id=request("id")
end if
DbPath = SERVER.MapPath("db1.mdb")
Set conn = Server.CreateObject("ADODB.Connection")
conn.open "driver={Microsoft Access Driver (*.mdb)};dbq=" & DbPath
sql="update mainboard set clicknum=clicknum+1 where id="&id
conn.execute sql
set rs2=server.createobject("ADODB.RecordSet")
sqltext1="select guestname,title,whattime,feeling,content,httptitle,httpadd,imgadd,renum,bianma from mainboard where id="&id
rs2.open sqltext1,conn
set rs1=server.createobject("ADODB.RecordSet")
sqltext="select id,guestname,title,whattime,feeling,content,httptitle,httpadd,imgadd from mainboard where fatherid="&id&" order by whattime"
rs1.open sqltext,conn,1,1
%>
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<style type="text/css">
<!--
.p12{font-family:"宋体";font-size:12pt;line-height:135%;}
.p9{font-family:"宋体";font-size:9pt;line-height:150%;}
td{font-family:"宋体";font-size:12pt;}
A:link{font-family:"宋体";color:blue;text-decoration:none}
A:visited{font-family:"宋体";color:blue;text-decoration:none}
A:hover{color:#FFFFFF;text-decoration:none;;background-color:#F0B8F8}
A:Active{color:#FF0000;}
.title{font-size:30pt;font-family:"楷体_GB2312"}
-->
</style>
<title>main board</title>
</head>
<body bgcolor="#FEECD3">
<table width="100%" border="1" bgcolor="#FCD7A5" bordercolorlight="#000000" bordercolordark="#FFFFFF" cellspacing="0" cellpadding="3">
<tr>
<td>
<p align="center"><big><img src="browimage\<%=trim(rs2("feeling"))%>.gif">
<strong><%=rs2("title")%></strong> -<a href="newmesg.asp?geter=<%=rs2("guestname")%>"><em><strong><font color="#0000FF"><%=rs2("guestname")%></font></strong></em></a>
于<font color="#FF8040"><%=rs2("whattime")%></font> 发表于<font color="#FF3333"><%=boardname%></font></big></p>
<%response.write replace(rs2("content"),chr(13)&chr(10),"<br>")
if rs2("httpadd")<>"" then%>
<p align="center"><a href="<%=rs2("httpadd")%>" target="_blank"><%if rs2("httptitle")="" then
response.write rs2("httpadd")
else
response.write rs2("httptitle")
end if%></a></p>
<%end if
if rs2("imgadd")<>"" then%>
<p align="center"><img border="0" src="<%=rs2("imgadd")%>"></p>
<%end if%> </td>
</tr>
</table><table width="100%" border="1" cellspacing="0" cellpadding="3" bordercolorlight="#000000" bordercolordark="#FFFFFF">
<%if rs1.recordcount>0 then
results=rs1.recordcount
for i=1 to results
%>
<tr bgcolor="#FFE7AD">
<td>
<h5><img src="browimage\<%=trim(rs1("feeling"))%>.gif"> <%=rs1("title")%>
-<a href="newmesg.asp?geter=<%=rs1("guestname")%>"><em><strong><font color="#0000FF"><%=rs1("guestname")%></font></strong></em></a>
回复于<font color="#FF8040"><%=rs1("whattime")%></font> <a href="delsb.asp?id=<%=id%>&cid=<%=rs1("id")%>&boardname=<%=boardname%>">删除</a></h5>
<p> <%response.write replace(rs1("content"),chr(13)&chr(10),"<br>")
if rs1("httpadd")<>"" then%> </p>
<p align="center"> <a href="<%=rs1("httpadd")%>" target="_blank"><%if rs1("httptitle")="" then
response.write rs1("httpadd")
else
response.write rs1("httptitle")
end if%></a></p>
<%end if
if rs1("imgadd")<>"" then%>
<p align="center"><img border="0" src="<%=rs1("imgadd")%>"></p>
<%end if%> </td> </tr><%rs1.movenext
if rs1.eof then
exit for
end if
next
end if
rs1.close
set rs1=nothing
rs2.close
set rs2=nothing
conn.close
set conn=nothing %>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -