%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%> <% Dim rs_news Dim rs_news_numRows Set rs_news = Server.CreateObject("ADODB.Recordset") rs_news.ActiveConnection = MM_mskg_STRING rs_news.Source = "SELECT * FROM LRNews WHERE id = (select max(id) from News where id < (SELECT MAX(id) FROM News))" rs_news.CursorType = 0 rs_news.CursorLocation = 2 rs_news.LockType = 1 rs_news.Open() rs_news_numRows = 0 %> <% Dim rs_newslast Dim rs_newslast_numRows Set rs_newslast = Server.CreateObject("ADODB.Recordset") rs_newslast.ActiveConnection = MM_mskg_STRING rs_newslast.Source = "SELECT * FROM LRNews ORDER BY ID DESC" rs_newslast.CursorType = 0 rs_newslast.CursorLocation = 2 rs_newslast.LockType = 1 rs_newslast.Open() rs_newslast_numRows = 0 %> <% Dim rs_newsarchived Dim rs_newsarchived_numRows Set rs_newsarchived = Server.CreateObject("ADODB.Recordset") rs_newsarchived.ActiveConnection = MM_mskg_STRING rs_newsarchived.Source = "SELECT * FROM LRNews WHERE Archived = 'y' ORDER BY DatePosted DESC" rs_newsarchived.CursorType = 0 rs_newsarchived.CursorLocation = 2 rs_newsarchived.LockType = 1 rs_newsarchived.Open() rs_newsarchived_numRows = 0 %> <% Dim rsnewshlines Dim rsnewshlines_numRows Set rsnewshlines = Server.CreateObject("ADODB.Recordset") rsnewshlines.ActiveConnection = MM_mskg_STRING rsnewshlines.Source = "SELECT * FROM LRNews WHERE Archived = 'N' ORDER BY ID DESC" rsnewshlines.CursorType = 0 rsnewshlines.CursorLocation = 2 rsnewshlines.LockType = 1 rsnewshlines.Open() rsnewshlines_numRows = 0 %> <% Dim Repeat2__numRows Dim Repeat2__index Repeat2__numRows = 10 Repeat2__index = 0 rs_newsarchived_numRows = rs_newsarchived_numRows + Repeat2__numRows %> <% Dim MM_paramName %> <% ' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters Dim MM_keepNone Dim MM_keepURL Dim MM_keepForm Dim MM_keepBoth Dim MM_removeList Dim MM_item Dim MM_nextItem ' create the list of parameters which should not be maintained MM_removeList = "&index=" If (MM_paramName <> "") Then MM_removeList = MM_removeList & "&" & MM_paramName & "=" End If MM_keepURL="" MM_keepForm="" MM_keepBoth="" MM_keepNone="" ' add the URL parameters to the MM_keepURL string For Each MM_item In Request.QueryString MM_nextItem = "&" & MM_item & "=" If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then MM_keepURL = MM_keepURL & MM_nextItem & Server.URLencode(Request.QueryString(MM_item)) End If Next ' add the Form variables to the MM_keepForm string For Each MM_item In Request.Form MM_nextItem = "&" & MM_item & "=" If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then MM_keepForm = MM_keepForm & MM_nextItem & Server.URLencode(Request.Form(MM_item)) End If Next ' create the Form + URL string and remove the intial '&' from each of the strings MM_keepBoth = MM_keepURL & MM_keepForm If (MM_keepBoth <> "") Then MM_keepBoth = Right(MM_keepBoth, Len(MM_keepBoth) - 1) End If If (MM_keepURL <> "") Then MM_keepURL = Right(MM_keepURL, Len(MM_keepURL) - 1) End If If (MM_keepForm <> "") Then MM_keepForm = Right(MM_keepForm, Len(MM_keepForm) - 1) End If ' a utility function used for adding additional parameters to these strings Function MM_joinChar(firstItem) If (firstItem <> "") Then MM_joinChar = "&" Else MM_joinChar = "" End If End Function %> <% Dim Repeat1__numRows Dim Repeat1__index Repeat1__numRows = 10 Repeat1__index = 0 rsnewshlines_numRows = rsnewshlines_numRows + Repeat1__numRows %>