
javastr="" 
javastr=javastr+"<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">" 
<!--#include file="conn.asp" --> 
<%
num=Request.QueryString("num")
if num="" then
num=10
end if
classid=Request.QueryString("classid")
if classid<>"" then 
sql="select top "&num&" * from article where lanmuid="&classid&" order by id desc"
else  
sql="select top "&num&" * from article order by id desc"
 end if 
 
set rs=conn.execute(sql)
do while not rs.eof
%> 
javastr=javastr+"<tr><td>" 
<% 
title=rs("title") 
    title=replace(title,"<","&lt;") 
    title=replace(title,">","&gt;") 
    title=replace(title,vbCrlf,"<br>")  
    title2=left(title,11)  'ÉèÖÃÏÔÊ¾10¸ö×Ö·û
if len(title2)<>len(title) then
    title2=title2&".."
end if
  if classid="" then  
%> 
javastr=javastr+"[<%=rs("date")%>]¡¤<a href=article.asp?id=<%=rs("id")%>&classid=<%=rs("lanmuid")%>target=_blank ><%=title%></a>" 

<%else
%>
javastr=javastr+"</td><td>¡¤<a href=article.asp?id=<%=rs("id")%>&classid=<%=classid%> title=\"<%=title%>\"target=_blank><%=title2%></a>" 
<%end if%>
 javastr=javastr+"</td></tr>" 
<%rs.movenext  
loop%>  
javastr=javastr+"</table>"  
document.write(javastr)  
<%rs.close%> 

