he econtrado esto que me devuelve un solo registro
Código PHP:
<%
dim rs_restaurantes_dest
dim rs_restaurantes_dest_numRows
Set rs_restaurantes_dest = Server.CreateObject("ADODB.Recordset")
rs_restaurantes_dest.ActiveConnection = MM_hotel_STRING
rs_restaurantes_dest.Source = "SELECT * FROM restaurantes WHERE destacado= 1"
rs_restaurantes_dest.CursorType = 3
rs_restaurantes_dest.CursorLocation = 2
rs_restaurantes_dest.LockType = 1
rs_restaurantes_dest.Open()
'rs_restaurantes_dest_numRows = 0
if Not rs_restaurantes_dest.EOF then
'rs_restaurantes_dest_mostra = "si"
dim rndmax_promo
rndmax_promo = cint(rs_restaurantes_dest.recordcount)
rs_restaurantes_dest.movefirst
dim rndnumber_promo
randomize timer
rndnumber_promo = int(rnd * rndmax_promo)
rs_restaurantes_dest.move rndnumber_promo
%>
<%=rs_restaurantes_dest("nombre")%><br />
<%' carry out your action here, with the appropriate recordset index
' for example response.redirect(objrs("url")) (requires response.buffer = true
or response.write("<img src=" & objrs("img") & ">")
else
end if%>
no se si poniendo un for o un while me mostrara 10 o mas registros