% intPageSize = 25 intPage = Request.QueryString("page") If intPage = "" Then intPage = 1 strSell = "Säljes" strBuy = "Köpes" strDate = DateAdd("d", -45, Now) %> <% Set RSShow = Server.CreateObject("ADODB.Recordset") If Request.QueryString("what") = "all" Or Request.QueryString("what") = "" Then Visa = "SELECT tblClass.*, tblClassCat.Name AS CatName, tblClassCat.SubCatID AS MainCatID FROM tblClass INNER JOIN tblClassCat ON tblClass.CatID = tblClassCat.ID WHERE tblClass.Datum > #" & strDate & "# AND tblClass.Deleted = False ORDER BY tblClass.Datum DESC, tblClass.ID DESC" ElseIf Request.QueryString("what") = "sell" Then Visa = "SELECT tblClass.*, tblClassCat.Name AS CatName, tblClassCat.SubCatID AS MainCatID FROM tblClass INNER JOIN tblClassCat ON tblClass.CatID = tblClassCat.ID WHERE tblClass.Datum > #" & strDate & "# AND tblClass.Type LIKE '" & strSell & "' AND tblClass.Deleted = False ORDER BY tblClass.Datum DESC, tblClass.ID DESC" ElseIf Request.QueryString("what") = "buy" Then Visa = "SELECT tblClass.*, tblClassCat.Name AS CatName, tblClassCat.SubCatID AS MainCatID FROM tblClass INNER JOIN tblClassCat ON tblClass.CatID = tblClassCat.ID WHERE tblClass.Datum > #" & strDate & "# AND tblClass.Type LIKE '" & strBuy & "' AND tblClass.Deleted = False ORDER BY tblClass.Datum DESC, tblClass.ID DESC" ElseIf Request.QueryString("what") = "search" Then Visa = "SELECT tblClass.*, tblClassCat.Name AS CatName, tblClassCat.SubCatID AS MainCatID FROM tblClass INNER JOIN tblClassCat ON tblClass.CatID = tblClassCat.ID WHERE tblClass.Datum > #" & strDate & "# AND tblClass.CatID = " & Request.QueryString("catID") & " AND tblClass.Deleted = False ORDER BY tblClass.Datum DESC, tblClass.ID DESC" End If With RSShow .ActiveConnection = Connect .Source = Visa .PageSize = intPageSize .CursorType = 3 .LockType = 1 .Open End With %>
<% If Request.QueryString("what") = "all" Or Request.QueryString("what") = "" Then %>
Visar Alla Annonser!
<% ElseIf Request.QueryString("what") = "sell" Then %>
Visar Alla Säljesannonser!
<% ElseIf Request.QueryString("what") = "buy" Then %>
Visar Alla Köpesannonser!
<% ElseIf Request.QueryString("what") = "search" Then
strCate = Request.QueryString("catID")
Set RSCate = Server.CreateObject("ADODB.Recordset")
Cate = "SELECT * FROM tblClassCat WHERE ID = " & strCate & " "
RSCate.Open Cate, Connect, adOpenDynamic, adLockOptimistic %>
Visar Annonser i Kategori: <% =RSCate("Name") %>
<% If Not RSShow.EOF Then
RSCate.Close
End If
End If %>
Annonser |
---|
Inga Annonser hittade... |
"><% =RSShow("Rubrik") %> <% =RSShow("Type") %> Kategori: <% =RSClassMain("Name") %> / <% =RSShow("CatName") %> <% =CropSentence(RSShow("Info"), 25, "...") %> Inlagd <% =RSShow("Datum") %> <% If Mid(Session("SbNuAdmin"), 5, 1) = "1" Then %> IP: <% =RSShow("IP") %> <% End If %> |
<% If strPostExist = True Then Call PageNavigation(intPage, intTotalPages) End If %>