<%@ LANGUAGE="VBSCRIPT" %> <% PageStrings = "18, 55, 57, 107, 108, 149, 150, 151, 152, 153, 154, 158, 160, 161, 265, 266, 648, 870, 871" %> <% recorprod = request.querystring("recorprod") SearchedID = request.querystring("PT_ID") prodtype = Request.Querystring("prodtype") recor = request.querystring("recor") PassedKeywords = sqlsafe(request.querystring("keywords")) PT_MasterCategory = sqlsafe(request.querystring("PT_MasterCategory")) SearchFor = sqlsafe(request.querystring("SearchFor")) keywords = sqlsafe(request.querystring("keywords")) PageHistory = sqlsafe(request.querystring("ph")) If recorprod="" then recorprod=1 If prodtype="" then prodtype=1 If recor="" then recor=1 If SearchedID="" then SearchedID=1 If Not IsNumeric(recorprod) then response.redirect("../ecommerce/error_occ.asp") If Not IsNumeric(prodtype) then response.redirect("../ecommerce/error_occ.asp") If Not IsNumeric(recor) then response.redirect("../ecommerce/error_occ.asp") If Not IsNumeric(SearchedID) and SearchedID<>"all" then response.redirect("../ecommerce/error_occ.asp") If PT_MasterCategory<>"y" then If DBType = "mysql" Then theQuery = "SELECT PT_Name, PT_ShortenedFormat, PT_Desc, PT_MotherProdType FROM tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID WHERE PT_Live='y' AND P_Live='y' AND PT_ID=" & prodtype Else theQuery = "SELECT PT_Name, PT_ShortenedFormat, PT_Desc, PT_MotherProdType FROM (tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID) INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID WHERE PT_Live='y' AND P_Live='y' AND PT_ID=" & prodtype End If Else theQuery = "SELECT PT_Name, PT_ShortenedFormat, PT_Desc, PT_MotherProdType FROM tbl_Prodtype WHERE PT_Live='y' AND PT_ID=" & prodtype End if Call ExecuteSQL(theQuery,cursortype,rs_main) IntNumRecs = rs_main.RecordCount If IntNumRecs>0 then PT_Name = rs_main("PT_Name") PT_ShortenedFormat = rs_main("PT_ShortenedFormat") PT_Desc = rs_main("PT_Desc") PT_MotherProdType = rs_main("PT_MotherProdType") End if rs_main.close numProdsPerPage = Application(HASHKEYNUMBERXYZ & "prodtypepagesize") If PT_ShortenedFormat="y" then numShortenValueCols = Application(HASHKEYNUMBERXYZ & "showshortenedformatcols") numProdsPerPage = numShortenValueCols * Application(HASHKEYNUMBERXYZ & "showshortenedformatrows") else numShortenValueCols=0 End if if numShortenValueCols>0 then extendedcatpage="n" else extendedcatpage="y" end if Call ReadFromTemplate(templatelocation,aryPageTemplate,strBasketHTML,strCategoryListHTML) response.write(aryPageTemplate(0)) If IntNumRecs=0 then %>
<% WriteString("ContentText_SectionUnavailable")%>
<% elseif PT_MasterCategory = "y" then theQuery = "SELECT * FROM tbl_Prodtype WHERE PT_MotherProdType=" & prodtype & " AND PT_Live='y' ORDER BY PT_Name, PT_ID" Call ExecuteSQL(theQuery,cursortype,rs_main) IntNumRecs = rs_main.RecordCount If IntNumRecs<>0 then %> <% do while not rs_main.EOF %> <% rs_main.moveNext loop %>
<% If PageHistory = "cat" then LocationBar = LocationBar & "" & GetString("ContentText_Categories") & " > " elseif PageHistory = "search" then LocationBar = LocationBar & "" & GetString("ContentText_Search") & " > " LocationBar = LocationBar & "" & GetString("ContentText_SearchResults")&" > " else LocationBar = LocationBar & "" & GetString("ContentText_Home") & " > " end if LocationBar = LocationBar & PT_Name response.write("" & PT_Name & "
" & LocationBar & "") %>
<% Set FSO = Server.CreateObject("Scripting.FileSystemObject") arrFileTypes = Split(Application(HASHKEYNUMBERXYZ & "allowedimages"), ",") theCategoryPath = Server.MapPath("../img_category/") theCategoryLargePath = Server.MapPath("../img_category_large/") theFile = GetFileLocation(theCategoryPath, prodtype, arrFileTypes, FSO) If theFile = "" Then strFileStatus = "" Else strFileStatus = "
" End if theFile = GetFileLocation(theCategoryLargePath, prodtype, arrFileTypes, FSO) If theFile = "" Then strFileStatus2 = "" Else If gfxSpex(theCategoryLargePath & "\" & theFile, imgW, imgH, c, strType) = True Then Item_Parent = PT_Name Item_Title = " (" & rs_main("PT_Name") & ")" Item_Image = server.URLencode("") strFileStatus2 = "" & GetString("ContentText_View2") & "" & GetString("ContentText_LargeView") & "   " End if End if response.write(strFileStatus) response.write(Highlight(PT_Desc, PassedKeywords, "mednormalhighlight")) response.write(strFileStatus2) %>
 
"><% =rs_main("PT_Name") %>
<% Set FSO = Server.CreateObject("Scripting.FileSystemObject") arrFileTypes = Split(Application(HASHKEYNUMBERXYZ & "allowedimages"), ",") theCategoryPath = Server.MapPath("../img_category/") theCategoryLargePath = Server.MapPath("../img_category_large/") theFile = GetFileLocation(theCategoryPath, rs_main("PT_ID"), arrFileTypes, FSO) If theFile = "" Then strFileStatus = "" Else strFileStatus = "
" End if theFile = GetFileLocation(theCategoryLargePath, rs_main("PT_ID"), arrFileTypes, FSO) If theFile = "" Then strFileStatus2 = "" Else If gfxSpex(theCategoryLargePath & "\" & theFile, imgW, imgH, c, strType) = True Then Item_Parent = PT_Name Item_Title = " (" & rs_main("PT_Name") & ")" Item_Image = server.URLencode("
") strFileStatus2 = "" & GetString("ContentText_View2") & "" & GetString("ContentText_LargeView") & "   " End if End if response.write(strFileStatus) response.write(Highlight(rs_main("PT_Desc"), PassedKeywords, "mednormalhighlight")) %>
 
<% end if rs_main.Close %> <% else If extendedcatpage ="y" then If DBType = "access" Then theQuery = "SELECT DISTINCTROW P_ID, P_StrapLine, P_Desc, P_Name, V_Price, V_CodeNumber, V_Name, V_ID, V_Desc, T_Taxrate, V_Live, V_Quantity, V_QuantityWarnLevel FROM (tbl_Versions INNER JOIN ((tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID) INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID) ON tbl_Versions.V_Product = tbl_Products.P_ID) INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID, V_Price, V_Name" ElseIf DBType = "mysql" Then theQuery = "SELECT DISTINCT P_ID, P_StrapLine, P_Desc, P_Name, V_Price, V_CodeNumber, V_Name, V_ID, V_Desc, T_Taxrate, V_Live, V_Quantity, V_QuantityWarnLevel FROM tbl_Versions INNER JOIN tbl_Products ON tbl_Versions.V_Product = tbl_Products.P_ID INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID, V_Price, V_Name" Else theQuery = "SELECT DISTINCT P_ID, P_StrapLine, P_Desc, P_Name, V_Price, V_CodeNumber, V_Name, V_ID, V_Desc, T_Taxrate, V_Live, V_Quantity, V_QuantityWarnLevel FROM (tbl_Versions INNER JOIN ((tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID) INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID) ON tbl_Versions.V_Product = tbl_Products.P_ID) INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID, V_Price, V_Name" End If Else If DBType = "access" Then theQuery = "SELECT DISTINCTROW P_ID, P_StrapLine, P_Desc, P_Name FROM (tbl_Versions INNER JOIN ((tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID) INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID) ON tbl_Versions.V_Product = tbl_Products.P_ID) INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID" ElseIf DBType = "mysql" Then theQuery = "SELECT DISTINCT P_ID, P_StrapLine, P_Desc, P_Name FROM tbl_Versions INNER JOIN tbl_Products ON tbl_Versions.V_Product = tbl_Products.P_ID INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID" Else theQuery = "SELECT DISTINCT P_ID, P_StrapLine, P_Desc, P_Name FROM (tbl_Versions INNER JOIN ((tbl_Products INNER JOIN tbl_ProductProdTypeLink ON tbl_Products.P_ID = tbl_ProductProdTypeLink.PPT_ProductID) INNER JOIN tbl_Prodtype ON tbl_ProductProdTypeLink.PPT_ProdTypeID = tbl_Prodtype.PT_ID) ON tbl_Versions.V_Product = tbl_Products.P_ID) INNER JOIN tbl_TaxRates ON tbl_Versions.V_Tax = tbl_TaxRates.T_ID WHERE V_Live ='y' AND P_Live = 'y' AND PT_Live = 'y' AND PT_ID=" & prodtype & " ORDER BY P_Name, P_ID" End If End If Call ExecuteSQL(theQuery,cursortype,rs_main) If IntNumRecs<>0 then %>
<% Set FSO = Server.CreateObject("Scripting.FileSystemObject") theProductPath = Server.MapPath("../img_product/") theVersionPath = Server.MapPath("../img_version/") theVersionLargePath = Server.MapPath("../img_version_large/") arrFileTypes = Split(Application(HASHKEYNUMBERXYZ & "allowedimages"), ",") do while recordnumber < (recorprod + numProdsPerPage-1) AND not rs_main.EOF recordnumber = recordnumber + 1 if numShortenValueCols=0 then %> <% If extendedcatpage = "y" then %> <% end if If recordmoved<>"y" then rs_main.moveNext else if recordnumber mod numProdsPerPage =1 then %>
We guarantee the cheapest prices, or we will refund DOUBLE THE DIFFERENCE

<% If PageHistory = "cat" then LocationBar = LocationBar & "" & GetString("ContentText_Categories") & " > " elseif PageHistory = "search" then LocationBar = LocationBar & "" & GetString("ContentText_Search") & " > " LocationBar = LocationBar & "" & GetString("ContentText_SearchResults") & " > " else LocationBar = LocationBar & "" & GetString("ContentText_Home") & " > " end if if PT_MotherProdType <> "0" then theQuery = "SELECT PT_Name FROM tbl_Prodtype WHERE PT_ID = " & PT_MotherProdType Call executeSQL(theQuery,cursortype,rs_main2) if rs_main.recordcount<>0 then LocationBar = LocationBar & "" & rs_main2("PT_Name") & " > " & chr(13) end if rs_main2.close end if LocationBar = LocationBar & PT_Name response.write("" & PT_Name & "
" & LocationBar & "") If recorprod<>1 then do until CInt(recordnumber) = CInt(recorprod) If nCurrentP_ID <> rs_main("P_ID") then recordnumber = recordnumber + 1 nCurrentP_ID = rs_main("P_ID") rs_main.movenext loop recordnumber = recordnumber - 1 rs_main.moveprevious end if %>
<% Set FSO = Server.CreateObject("Scripting.FileSystemObject") arrFileTypes = Split(Application(HASHKEYNUMBERXYZ & "allowedimages"), ",") theCategoryPath = Server.MapPath("../img_category/") theCategoryLargePath = Server.MapPath("../img_category_large/") theFile = GetFileLocation(theCategoryPath, prodtype, arrFileTypes, FSO) If theFile = "" Then strFileStatus = "" Else strFileStatus = "
" End if theFile = GetFileLocation(theCategoryLargePath, prodtype, arrFileTypes, FSO) If theFile = "" Then strFileStatus2 = "" Else If gfxSpex(theCategoryLargePath & "\" & theFile, imgW, imgH, c, strType) = True Then Item_Image = server.URLencode("") strFileStatus2 = "" & GetString("ContentText_View2") & "" & GetString("ContentText_LargeView") & "   " End if End if response.write(strFileStatus & "
") response.write(Highlight(PT_Desc, PassedKeywords, "mednormalhighlight")) %>
 
<% Response.Write(rs_main("P_Name")) %>
<% WriteString("ContentText_ViewProductMoreDetail") %> >>

<% If rs_main("P_StrapLine")<>"" then %> <% =rs_main("P_StrapLine") %>

<% end if response.write(rs_main("P_Desc")) %>
<% theFile = GetFileLocation(theProductPath, RS_Main("P_ID"), arrFileTypes, FSO) If theFile = "" Then strFileStatus = "" Else strFileStatus = "" End if Response.Write(strFileStatus) %>
<% 'modify product row specifics here %> <% bg=0 nCurrentP_ID = rs_main("P_ID") do while ((nLastP_ID = nCurrentP_ID) OR (Cint(nLastP_ID=0))) AND NOT rs_main.EOF bg = bg + 1 numLineCount = numLineCount + 1 numPrice = Round(rs_main("V_Price"),2) numTax = rs_main("T_Taxrate")/100 numPriceExTax = Round(numPrice * (1/(1 + numTax)),2) If bg/2 = Int(bg/2) then bgcolor="mainpagetableline" else bgcolor="mainpagetableline2" end if If rs_main("V_ID") = CInt(version) then bgcolor="mainpageversionhighlight" strReturnURL = "product.aspquestionmarkprodtype=" & prodtype & "ampersandrecorprod=" & recorprod & "ampersandph=" & phclause %> <% rs_main.moveNext If Not rs_main.EOF then nLastP_ID = rs_main("P_ID") recordmoved="y" loop %>
<% WriteString("ContentText_ProductItem")%> <% WriteString("ContentText_CodeNumberSmall")%> <% WriteString("ContentText_Price") %> (<% =Application(HASHKEYNUMBERXYZ & "currencyunit") %>)  <% WriteString("ContentText_Quantity") %>               
<% end if numColumnWidthPercent = 100/numShortenValueCols %> <% if (recordnumber=rs_main.recordcount) OR (recordnumber mod numProdsPerPage = 0) then numModValue = (recordnumber mod numProdsPerPage) mod numShortenValueCols numExtraCells = numShortenValueCols-numModValue If numExtraCells = numShortenValueCols then numExtraCells=0 For numCellCounter = 1 to numExtraCells %> <% next %> <% end if If recordnumber mod numShortenValueCols = 0 then %> <% end if rs_main.moveNext end if loop if numShortenValueCols>0 then %>
 
<% response.write("" & rs_main("P_Name") & "") %>
<% theFile = GetFileLocation(theProductPath, RS_Main("P_ID"), arrFileTypes, FSO) If theFile = "" Then strFileStatus = "" Else strFileStatus = "" End if Response.Write(strFileStatus) If rs_main("P_StrapLine")<>"" then %>
<% =rs_main("P_StrapLine") %> <% end if %>
 
<% end if rs_main.Close Set FSO = Nothing if recordnumber>numProdsPerPage then strPageLinks = strPageLinks & "<< " & GetString("ContentText_Previous") & "" & chr(13) end if If IntNumRecs>numProdsPerPage then for t = 1 to CInt((IntNumRecs/numProdsPerPage)+0.49) strPageLinks = strPageLinks & " " & chr(13) If Cint(recorprod)<>(numProdsPerPage*(t-1))+1 then strPageLinks = strPageLinks & "" & t & "" else strPageLinks = strPageLinks & (t) end if next strPageLinks = strPageLinks & chr(13) End if if IntNumRecs>recordnumber then strPageLinks = strPageLinks & " " & GetString("ContentText_Next") & " >>" & chr(13) %>   <% response.write(strPageLinks) %> Free delivery all orders over $75
<% else %>
<% WriteString("ContentText_SectionUnavailable")%>
<% end if end if response.write(aryPageTemplate(1)) DataConn.Close set DataConn = nothing %>