<% dim sselect GetDBConnect set srs = server.CreateObject("ADODB.RECORDSET") srs.open "select * from producttype",conn,1,1 if not(srs.eof and srs.bof) then while not srs.eof sselect = sselect&"" set prs = server.CreateObject("ADODB.RECORDSET") prs.open "select * from product where typeid="&srs("id"),conn,1,1 if not(prs.eof and prs.bof) then while not prs.eof if prs("id")=id then sselect = sselect&"" else sselect = sselect&"" end if prs.movenext wend prs.close set prs = nothing else sselect = sselect&"" end if srs.movenext wend srs.close set srs = nothing else sselect = "" end if %>

产品

网站新闻:
    <% set nrs = server.CreateObject("ADODB.RECORDSET") nrs.open "select id,title from news order by date desc",conn,1,1 if nrs.eof and nrs.bof then %>
  • 找不任何新闻
  • <% else while not nrs.eof %>
  • " target="_blank"><%=nrs("title")%>
  • <% nrs.movenext wend end if nrs.close set nrs = nothing %>