<%call listnews("select top 9 * from news order by adddate desc","indexnewslistright")%>
用这个为什么只返回每个条目前20个字?<%functionlistnews(db,div)%><%dimrs1setrs1=server.createobject("ad...
用这个为什么只返回每个条目前20个字?
<%function listnews(db,div)%>
<%dim rs1
set rs1=server.createobject("adodb.recordset")
rs1.open ""&db&" ",conn,1,1
if not (rs1.eof and rs1.bof ) then
i=1
do while not rs1.eof %>
<div id="<%=div%>"> <%if div="indexnewslistleft" then%><img src="images/gif-0163.gif"> <%else%><img src="images/gif-0164.gif"> <%end if%><a href="<%=weburl%>/news.asp?newsid=<%=rs1("id")%>"><%=LeftT(rs1("name"),11)%></a>
</div>
<%rs1.movenext
i=i+1
loop
end if
rs1.close
set rs1=nothing
%>
<%end function%>
是这个吗? 展开
<%function listnews(db,div)%>
<%dim rs1
set rs1=server.createobject("adodb.recordset")
rs1.open ""&db&" ",conn,1,1
if not (rs1.eof and rs1.bof ) then
i=1
do while not rs1.eof %>
<div id="<%=div%>"> <%if div="indexnewslistleft" then%><img src="images/gif-0163.gif"> <%else%><img src="images/gif-0164.gif"> <%end if%><a href="<%=weburl%>/news.asp?newsid=<%=rs1("id")%>"><%=LeftT(rs1("name"),11)%></a>
</div>
<%rs1.movenext
i=i+1
loop
end if
rs1.close
set rs1=nothing
%>
<%end function%>
是这个吗? 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询