如何当产品分类到了8种就分列显示呢
<%
Dim NoClass2
NoClass2=1
NoClass1=1
Set rs = Server.Createobject("ADODB.recordset")
asql="select top 20 * from BigClass where NoClass='"&NoClass2&"' order by BgOrder asc"
rs.open asql,Cn
%>
<%
if not rs.eof and not rs.bof then
while not rs.eof
BigClass_Cp=rs("BigClass")
ClassCode_Cp=rs("ClassCode")
Set rs1 = Server.Createobject("ADODB.recordset")
bsql="select top 1 * from Article where BigClass='"&ClassCode_Cp&"' and NoClass='"&NoClass1&"' order by id desc"
rs1.open bsql,Cn
if rs1.eof and rs1.bof then
else
%>
<div id=CpList01><img src=images/c1.JPG border=0><a href=<%=Web_WebUrl%><%=ClassCode_Cp%>.html title='<%=BigClass_Cp%>'><%=BigClass_Cp%></a></div>
<%
rs1.close
set rs1=nothing
end if
rs.movenext
wend
rs.close
set rs=nothing
end if
%>