<%@ LANGUAGE="VBSCRIPT" %> <% HTMLtitle="My Cart" %> <% Function AddToExistingItem(V,ARYcart2) For comp = 0 to 50 If ARYcart2(comp,1) = V then ARYcart2(comp,2) = ARYcart2(comp,2) + 1 duplicate = 1 'iCount = iCount-1 end if next AddToExistingItem = ARYcart2 End Function Function AddNewItemLine(V,ARYcart2) ARYcart2(iCount,1) = V ARYcart2(iCount,2) = 1 AddNewItemLine = ARYcart2 iCount = iCount + 1 End Function Function TagRowForDeletion(R,ARYcart2) For comp = 0 to 50 If ARYcart2(comp,1) = R then ARYcart2(comp,1) = "" ARYcart2(comp,2) = "" iCount = iCount - 1 end if next TagRowForDeletion = ARYcart2 End Function Function SquashOutSpaces(ARYcart2) For comp = 0 to 49 If ARYcart2(comp,2) = "" then ARYcart2(comp,1) = ARYcart2(comp + 1,1) ARYcart2(comp,2) = ARYcart2(comp + 1,2) ARYcart2(comp + 1,1) = "" ARYcart2(comp + 1,2) = "" end if next SquashOutSpaces = ARYcart2 End Function duplicate = 0 thispage="basket" ARYcart2=ARYcart V = Request.QueryString("V") if V = "" then v = "refresh" If request("submit")="Apply changes" then for tt = 1 to iCount ARYcart2(tt-1,2) = (Request.querystring("T" & tt)) if Not IsNumeric(ARYcart2(tt-1,2)) then ARYcart2(tt-1,2) = "" iCount = iCount - 1 end if if ARYcart2(tt-1,2) = "0" then ARYcart2(tt-1,2) = "" iCount = iCount - 1 end if If IsNumeric(ARYcart2(tt-1,2)) then ARYcart2(tt-1,2) = Int(ARYcart2(tt-1,2)) If ARYcart2(tt-1,2) < 0 then ARYcart2(tt-1,2) = "" iCount = iCount - 1 end if end if next end if If V <> "refresh" and V <> "remove" then ARYcart2 = AddToExistingItem(V,ARYcart2) If duplicate = 0 then ARYcart2 = AddNewItemLine(V,ARYcart2) end if end if If V = "remove" then R = request("R") ARYcart2 = TagRowForDeletion(R,ARYcart2) end if For y = 1 to 50 ARYcart2 = SquashOutSpaces(ARYcart2) next '----------------------------------------------- 'WRITE BASKET CONTENTS TO A COOKIE '----------------------------------------------- %> <% '----------------------------------------------- 'REDIRECT TO EMPTY CART PAGE '----------------------------------------------- If Request.querystring("Empty")="Empty Cart" then response.redirect("emptycart.asp") end if '----------------------------------------------- 'READ PAGE TEMPLATE FROM FILE '----------------------------------------------- '----------------------------------------------- 'WRITE FIRST HALF OF PAGE HTML '----------------------------------------------- 'response.write(request.cookies(cookiename)("Qty")) 'response.write("
") 'response.write(request.cookies(cookiename)("Items")) 'response.write("
") 'response.write(request.cookies(cookiename)("Icount")) 'response.write("
") If iCount>0 then response.write(HTMLtop) %>
<% response.write(changesmade) %>
Currently we only deliver to customers in the United Kingdom                         
<% bgcolourtieku=1 for lp = 1 to iCount '----------------------------------------------- 'SUCK THE CONTENTS OF AN ARRAY RECORD FROM DB '----------------------------------------------- theQuery = "SELECT * FROM TaxRates INNER JOIN (Versions INNER JOIN (Products INNER JOIN Prodtype ON Products.P_Prodtype = Prodtype.PT_ID) ON Versions.V_Product = Products.P_ID) ON TaxRates.T_ID = Versions.V_Tax WHERE (((Versions.V_ID)=" & ARYcart2(lp-1,1) & "));" Call ExecuteSQL(theQuery,cursortype,rs_main) price = Round(rs_main("V_Price"),2) tax = 0 pricetax = 0 totalprice = totalprice + (ARYcart2(lp-1,2)*(pricetax + price)) totalpriceextax = totalpriceextax + (price*ARYcart2(lp-1,2)) totaltax = Round(totalprice - totalpriceextax,2) 'Other currecnies if request.cookies("dtmcurrency")("ID") <> "" then theQuery = "SELECT * FROM Rates where R_ID ="& request.cookies("dtmcurrency")("ID") & ";" Call ExecuteSQL(theQuery,cursortype,rs_main3) if rs_main3.recordcount > 0 then crate=(rs_main3("R_Rate")*1) c100=rs_main3("R_100") cprice = ((price*ARYcart2(lp-1,2))*1)*(rs_main3("R_Rate")*1) if cprice>=1 then curency = rs_main3("R_100") & pounds(cprice) & " (APPROX)" else curency = (pounds(cprice)*100) & rs_main3("R_1") & " (APPROX)" end if currency1 = " - " & curency end if rs_main3.Close end if %> > <% rs_main.Close if bgcolourtieku=1 then bgcolourtieku=0 else bgcolourtieku=1 end if next %>
Code Per item QTY Price

><% response.write(rs_main("P_Name")) %> >£<%response.write(Pounds(price*ARYcart2(lp-1,2)) & currency1)%>
>&V=<% =rs_main("V_ID") %>"><% response.write(rs_main("V_Name")) %> nowrap><% response.write(rs_main("V_CodeNumber"))%> >£<%response.write(Pounds(rs_main("V_Price")))%> > >'">

TOTAL PRICE = <% response.write("£"& Pounds(Round(totalprice,2))) %><% if request.cookies("dtmcurrency")("ID") <> "" then response.write(" - " & c100 & pounds(Round(totalprice*crate,2))) %>

Payment Options

Please click on the buttom next to the payment method you want to use below:


Pay online using Nochex with your credit or debit card

www.nochex.com

Pay online using Paypal with your credit or debit card

www.paypal.com

Send Payment by Post

Use this method to send a cheque, cash, postal order or a bank transfer to us for your order.


<% else response.cookies(cookiename).expires=now()-1 response.write(HTMLtop) Response.write("Your cart is currently empty") end if '----------------------------------------------- 'WRITE HTML '----------------------------------------------- response.write(HTMLbottom) '----------------------------------------------- 'CLOSE DATA CONNECTIONS '----------------------------------------------- DataConn.Close set DataConn = nothing %>