<%
dim dia
sql = "select distinct fecha from ciec_titulares where tema='"& request("tema") &"' order by fecha desc"
registros.open sql,conexion,1
if not registros.bof and not registros.eof then
do while not registros.eof
%>
<%
response.write(datepart("d",registros("fecha")))
dim mes
mes=datepart("m",registros("fecha"))
select case mes
case 1 mes="enero"
case 2 mes="febrero"
case 3 mes="marzo"
case 4 mes="abril"
case 5 mes="mayo"
case 6 mes="junio"
case 7 mes="julio"
case 8 mes="agosto"
case 9 mes="septiembre"
case 10 mes="octubre"
case 11 mes="noviembre"
case 12 mes="diciembre"
end select
response.write(" de "+mes+" de ")
response.write(datepart("yyyy",registros("fecha")))
%>
<%
dia=registros("fecha")
sql = "select * from ciec_titulares where fecha='"& dia &"' and estado=1 and tema='"& request("tema") &"' order by id desc"
registros2.open sql,conexion,1
if not registros2.bof and not registros2.eof then
do while not registros2.eof%>
,
<%=registros2("fuente")%> <%if registros2("veces")=mayor_var then%>¡Artículo mas votado!<%end if%>
<%registros2.movenext
loop
end if
registros2.close
registros.movenext
loop
end if
registros.close
set registros = Nothing
conexion.close
set conexion = Nothing
%>