<% Dim FechaPublica FechaPublica = Year(Date()) & "" & Right("0"& Month(Date()),2) & "" & Right("0"& Day(Date()),2) %> <% Dim oRsBanners Dim oRsBanners_cmd Dim oRsBanners_numRows Set oRsBanners_cmd = Server.CreateObject ("ADODB.Command") oRsBanners_cmd.ActiveConnection = MM_bannersC_STRING oRsBanners_cmd.CommandText = "SELECT * FROM Bannersv4 WHERE FechaPublica <= '"&FechaPublica&"' AND FechaTermina >= '"&FechaPublica&"' AND Estatus = 's' ORDER BY Posicion, FechaAlta ASC" oRsBanners_cmd.Prepared = true Set oRsBanners = oRsBanners_cmd.Execute oRsBanners_numRows = 0 %> <% Dim Repeat1__numRows Dim Repeat1__index Repeat1__numRows = -1 Repeat1__index = 0 oRsBanners_numRows = oRsBanners_numRows + Repeat1__numRows %> <% Dim Repeat1__numRowsT Dim Repeat1__indexT Repeat1__numRowsT = -1 Repeat1__indexT = 0 oRsBanners_numRowsT = oRsBanners_numRowsT + Repeat1__numRowsT %> <% IF ((NOT oRsBanners.EOF)) THEN %>
<% oRsBanners.MoveFirst While ((Repeat1__numRowsT <> 0) AND (NOT oRsBanners.EOF)) %> <% Dim tmp_URLt tmp_URLt = oRsBanners.Fields.Item("URL").Value %> <% IF tmp_URLt <> "" THEN %> " target="_blank">" width="110" border="0"/><%=(Repeat1__indexT)%> <% ELSE %> ">" width="110" border="0"/><%=(Repeat1__indexT)%> <% END IF %> <% Repeat1__indexT=Repeat1__indexT+1 Repeat1__numRowsT=Repeat1__numRowsT-1 oRsBanners.MoveNext() Wend %>
<% END IF %> <% If oRsBanners.EOF And oRsBanners.BOF Then %>

<% End If ' end oRsBanners.EOF And oRsBanners.BOF %> <% oRsBanners.Close() Set oRsBanners = Nothing %>