<% If Not session("admin_loggedin" & strSUnique) = Session.SessionID then Response.Redirect "default.asp" msgNomarkes = "

The Editor's Pick List is Empty.

" set rsf = objConn.Execute("SELECT " & tablPfx & "Main.editor_pick FROM " & tablPfx & "Main;") If not rsf.EOF then fList = rsf(0) rsf.close If Len(fList) > 0 then newfList = fList fArray = Split(fList) For ep = 0 to Ubound(fArray) Set rscheck = objConn.Execute("SELECT ID FROM " & tablPfx & "Ads WHERE adID = '" & fArray(ep) & "';") If rscheck.EOF And Not Len(fArray(ep)) = 0 Then newfList = Replace(newfList, " " & fArray(ep), "") rscheck.close Next If Not Trim(fList) = Trim(newfList) Then objConn.Execute("UPDATE " & tablPfx & "Main SET editor_pick ='" & newfList & "';") End If If Len(Request.Form("C1")) > 0 Then For each item in Request("C1") fList = Replace(fList, " " & item, "") Next If Len(fList) < 2 then fList = null strSQL = "UPDATE " & tablPfx & "Main SET editor_pick = '" & fList & "';" objConn.Execute(strSQL) End If fList = Trim(fList) %>
Editor's Pick

<% If Len(fList) > 0 then fArray = Split(fList) For each item in fArray strCondition = strCondition & " OR adID = '" & item & "'" Next strCondition = Replace(strCondition, "OR", "", 1, 1) strSQL = "SELECT pdate,subject,userID,nick,adID,hotlist FROM " & tablPfx & "Ads WHERE (status = 1) AND (" & strCondition & ") ORDER BY hotlist DESC;" set rsf = objConn.Execute(strSQL) If rsf.EOF then Response.Write msgNomarkes Else Response.Write msgHead %>
<% J = 0 Do while not rsf.EOF iDate = FormatDateTime(rsf(0), 2) subject = rsf(1) auserID = rsf(2) nick = rsf(3) adID = rsf(4) subject = "" & subject & "" If Cbool(rsf(5)) then subject = " " & subject nick = "" & nick & "" If J mod 2 = 0 then cellColor = "class='evencell'": Else: cellColor = "class='oddcell'" %> <% J = J + 1 rsf.MoveNext Loop %>
Posted on: Subject: Author: Remove:
><%= iDate %> > <%= subject %> ><%= nick %> >

<% End If Else: Response.Write msgNomarkes End If %>
Admin Tasks | Home | Logout