level 13
金鳌
楼主
<%
set rs=server.CreateObject("adodb.recordset")
str="select top 2 * from [hn_Tourism] where classId=8 and smallPic<>'' order by id desc"
rs.open str,conn,3,1
if not rs.eof and not rs.bof then
id=rs("id")
%>
<table width="304" border="0" cellspacing="0" cellpadding="0" style="float:left">
<tr>
<td width="154" valign="top"><a href="/lvyou/article.asp?id=<%=rs("id")%>" target="_blank"><img src="/<%=rs("smallPic")%>" width="142" height="94" style="border:1px solid #cdcdcd; padding:1px;" /></a></td>
<td width="150" valign="top">
<div class="To_TT_box_T"><%=rs("title")%></div>
<div class="To_TT_box_desc"><%=left(RemoveHTML(rs("content")),30)%>...</div>
</td>
</tr>
</table>
<%
end if
rs.close
set rs=nothing
%>
我是想读取2条信息的。
2015年05月05日 00点05分
1
set rs=server.CreateObject("adodb.recordset")
str="select top 2 * from [hn_Tourism] where classId=8 and smallPic<>'' order by id desc"
rs.open str,conn,3,1
if not rs.eof and not rs.bof then
id=rs("id")
%>
<table width="304" border="0" cellspacing="0" cellpadding="0" style="float:left">
<tr>
<td width="154" valign="top"><a href="/lvyou/article.asp?id=<%=rs("id")%>" target="_blank"><img src="/<%=rs("smallPic")%>" width="142" height="94" style="border:1px solid #cdcdcd; padding:1px;" /></a></td>
<td width="150" valign="top">
<div class="To_TT_box_T"><%=rs("title")%></div>
<div class="To_TT_box_desc"><%=left(RemoveHTML(rs("content")),30)%>...</div>
</td>
</tr>
</table>
<%
end if
rs.close
set rs=nothing
%>
我是想读取2条信息的。