<% Dim Currpage, pageLen, lastNumber, PageRem, PageTen Dim connection, rsGetProducts, sSQL, sConnString, next10, prev10, P Dim RSPrevPage, RSNextPage, start If IsEmpty(Request.Querystring("PageNo")) then CurrPage = 1 Else CurrPage = Cint(Request.Querystring("PageNo")) End If Function getNext10(num) pageLen = len(num) If pageLen = 1 Then next10 = 12 Else If pageLen>1 Then pageRem = 12 pageTen = right(num, 1) next10 = num + pageRem - pageTen End If End If getNext10 = next10 End Function Function getPrev10(num) pageLen = len(num) If pageLen = 1 then prev10 = 1 Else If pageLen>1 then lastNumber = right(num, 1) prev10 = num - lastNumber - 12 End If End If If prev10 = 0 then prev10 = 1 End If getPrev10 = prev10 End Function Set rsGetProducts=Server.CreateObject("Adodb.Recordset") rsGetProducts.CursorLocation = 3 rsGetProducts.CursorType = 3 qry = "select * from products where categoryid = "& sql_filter(valid_sql(Request.QueryString("categoryid"))) rsGetProducts.open qry, conn rsGetProducts.PageSize=12 rsGetProducts.AbsolutePage = CurrPage next10 = getNext10(CurrPage) prev10 = getPrev10(CurrPage) %> Welcome To BlackBridalGuide.com - African American Wedding Planning Jumping Brooms African American Bridal Hairstyles, African American Wedding Planners <% Set rsmeta=Server.CreateObject("Adodb.Recordset") qry = "select * from products where categoryid = 30" rsmeta.open qry, conn if not rsmeta.bof or not rsmeta.eof then do until rsmeta.eof meta = meta & rsmeta("productname") & ", " rsmeta.movenext loop end if rsmeta.close set rsmeta = nothing %>
<%=request("category")%> <% RSPrevPage = CurrPage - 1 RSNextPage = CurrPage + 1 If Next10 > rsGetProducts.PageCount Then Next10 = rsGetProducts.PageCount End If If prev10 = 1 AND next10 - 1 < 10 Then start = 1 Else start = Next10 - 10 If right(start, 1) > 0 Then start = replace(start, right(start, 1), "0") start = start + 10 End If End If If rsGetProducts.PageCount > 1 Then If next10 > 10 Then%> &category=<%=request("category")%>&pageno=<%=Prev10%>" > << Previous  <%End If If NOT RSPrevPage = 0 then%> &category=<%=request("category")%>&pageno=<%=Prev10%>" > < First  <%End If For P = start to Next10 If NOT P = CurrPage then%> &category=<%=request("category")%>&pageno=<%=P%>"><%=P%> <%Else response.write(" " & P & " ") End If Next If NOT RSNextPage > rsGetProducts.PageCount Then%> &category=<%=request("category")%>&pageno=<%=RSNextPage%>"> Next > <%End If If NOT Next10 = rsGetProducts.PageCount Then%> &category=<%=request("category")%>&pageno=<%=Next10%>"> Last >>") <%End If End If %>
<%if not rsGetProducts.bof or not rsGetProducts.eof then%> <%i = intstart xtd = 0 Do Until rsGetProducts.AbsolutePage <> CurrPage OR rsGetProducts.Eof if xtd mod 3 = 0 then Response.Write("") end if Path = Server.MapPath ("prodimages/"&rsGetProducts("imagepath")&"") %> <%i = i + 1 xtd = xtd + 1 rsGetProducts.movenext If rsGetProducts.EOF Then exit do Loop%> <%else%> <%end if%>

<%=rsGetProducts("productname")%>
Size: <%=rsGetProducts("productsize")%>
Price: $<%=rsGetProducts("productprice")%>
" name="productid" /> " name="productprice" /> " name="productsize" /> " name="productname" />
&pageno=<%=currpage%>">
There is no products available in this category. Please check this page later.
<% RSPrevPage = CurrPage -1 RSNextPage = CurrPage + 1 If Next10 > rsGetProducts.PageCount Then Next10 = rsGetProducts.PageCount End If If prev10 = 1 AND next10 - 1 < 10 Then start = 1 Else start = Next10 - 10 If right(start, 1) > 0 Then start = replace(start, right(start, 1), "0") start = start + 10 End If End If If rsGetProducts.PageCount > 1 Then If next10 > 10 Then%> &category=<%=request("category")%>&pageno=<%=Prev10%>" > << Previous  <%End If If NOT RSPrevPage = 0 then%> &category=<%=request("category")%>&pageno=<%=Prev10%>" > < First  <%End If For P = start to Next10 If NOT P = CurrPage then%> &category=<%=request("category")%>&pageno=<%=P%>"><%=P%> <%Else response.write(" " & P & " ") End If Next If NOT RSNextPage > rsGetProducts.PageCount Then%> &category=<%=request("category")%>&pageno=<%=RSNextPage%>"> Next > <%End If If NOT Next10 = rsGetProducts.PageCount Then%> &category=<%=request("category")%>&pageno=<%=Next10%>"> Last >>") <%End If End If %>