<% ' Comersus Shopping Cart ' Comersus Open Technologies ' United States ' Software License can be found at License.txt ' http://www.comersus.com ' Details: show cart contents %> <% on error resume next dim mySQL, connTemp, rsTemp, rsTemp2, rsTemp7, pDefaultLanguage, pStoreFrontDemoMode, pCurrencySign, pDecimalSign, pMoneyDontRound, pCompany, pCompanyLogo, pHeaderKeywords, pAuctions, pListBestSellers, pNewsLetter, pPriceList, pStoreNews, pOneStepCheckout, pRealTimeShipping, pAllowNewCustomer, pByPassShipping, total, totalDeliveringTime, pIdDbSession, pIdDbSessionCart, pIdCustomer, pIdCustomerType, pLanguage, pCustomerName, pHeaderCartItems, pHeaderCartSubtotal, pAffiliatesStoreFront, pIdCartRow, pIdProduct, pQuantity, pUnitPrice, pDescription, pSku, pDeliveringTime, pPersonalizationDesc, pRental, pItHasFreeProduct, pDetails, pOptionGroupsTotal, pRowPrice, pBonusPoints ' get settings pStoreFrontDemoMode = getSettingKey("pStoreFrontDemoMode") pCurrencySign = getSettingKey("pCurrencySign") pDecimalSign = getSettingKey("pDecimalSign") pCompany = getSettingKey("pCompany") pCompanySlogan = getSettingKey("pCompanySlogan") pAboutUsLink = getSettingKey("pAboutUsLink") pHeaderKeywords = getSettingKey("pHeaderKeywords") pMoneyDontRound = getSettingKey("pMoneyDontRound") pByPassShipping = getSettingKey("pByPassShipping") pTaxIncluded = getSettingKey("pTaxIncluded") pRealTimeShipping = getSettingKey("pRealTimeShipping") pAllowNewCustomer = getSettingKey("pAllowNewCustomer") pAffiliatesStoreFront = getSettingKey("pAffiliatesStoreFront") pSuppliersList = getSettingKey("pSuppliersList") pAuctions = getSettingKey("pAuctions") pNewsLetter = getSettingKey("pNewsLetter") pShowNews = getSettingKey("pShowNews") total = Cdbl(0) totalDeliveringTime = Cdbl(0) pIdDbSession = checkSessionData() pIdDbSessionCart = checkDbSessionCartOpen() pIdCustomer = getSessionVariable("idCustomer",0) pIdCustomerType = getSessionVariable("idCustomerType",1) pDiscountCode = getSessionVariable("discountCode","") ' check if the cart is empty if countCartRows(pIdDbSessionCart)=0 then response.redirect "comersus_message.asp?message="&Server.Urlencode(getMsg(40,"emtpy")) end if call customerTracking("comersus_showCart.asp", request.querystring) pSubTotal = calculateCartTotal(pIdDbSessionCart) %>
<%=getMsg(42,"Your cart contains")%>
<% ' get all products in the cart mySQL="SELECT idCartRow, cartRows.idProduct, quantity, unitPrice, description, sku, deliveringTime, personalizationDesc, rental FROM cartRows, products WHERE cartRows.idProduct=products.idProduct AND cartRows.idDbSessionCart="&pIdDbSessionCart call getFromDatabase(mySQL, rstemp, "showCart") do while not rstemp.eof pIdCartRow = rstemp("idCartRow") pIdProduct = rstemp("idProduct") pQuantity = rstemp("quantity") pUnitPrice = Cdbl(rstemp("unitPrice")) pDescription = rstemp("description") pSku = rstemp("sku") pDeliveringTime = rstemp("deliveringTime") pPersonalizationDesc = rstemp("personalizationDesc") pRental = rstemp("rental") %> <% if Cint(pDeliveringTime)>totalDeliveringTime then totalDeliveringTime = Cint(pDeliveringTime) end if rstemp.moveNext loop %>
<%=getMsg(43,"Qty")%> <%=getMsg(44,"Item")%> <%=getMsg(45,"Opt")%> <%=getMsg(46,"Price")%> <%=getMsg(47,"Act")%>
<%=pSku%> - <%=pDescription%> <%if pPersonalizationDesc<>"" then response.write " (" &pPersonalizationDesc& ")"%> <%=getCartRowOptionals(pIdCartRow)%> <%=pCurrencySign & money(getCartRowPrice(pIdCartRow))%> <%=getMsg(48,"remove")%>

">
<%if pDiscountCode<>"" then%> <% pDiscountDesc ="" pDiscountTotal =0 call getDiscount(pDiscountCode, pDiscountDesc, pDiscountTotal) pSubTotal=pSubTotal-pDiscountTotal %>

<%=getMsg(443,"discount")%>: <%=pDiscountDesc%> - <%=pCurrencySign & money(pDiscountTotal)%> [<%=getMsg(48,"remove")%>] <%else%> <%if pStoreFrontDemoMode="-1" then%>
<%=getMsg(443,"discount")%>
<%else%>
<%=getMsg(443,"discount")%>
<%end if%> <%end if%>
<%=getMsg(50,"Total")%> <%=pCurrencySign & money(pSubTotal) %> <%if pTaxIncluded<>"-1" then%> <%=getMsg(51,"Tx inc")%>
<%else%> <%=getMsg(52,"Tax n/incl")%>
<%end if%> <%=getMsg(53,"Availability")%> <% if totalDeliveringTime>0 and totalDeliveringTime<999 then response.write totalDeliveringTime & " " & getMsg(54," days") end if if totalDeliveringTime=0 then response.write getMsg(56,"same day") end if ' use 999 for undetermined if totalDeliveringTime>998 then response.write getMsg(55,"Und") end if %>

<%=getMsg(57,"Keep sh")%> <%if ucase(pRealTimeShipping)="NONE" and pByPassShipping="0" then%>
<%=getMsg(59,"Get sh cost")%> <%end if%> <%if pIdCustomer<>0 then%>
">
<%else%>

<%=getMsg(58,"Checkout")%>

<%if pAllowNewCustomer="-1" and (pTeleSignCustomerId="0" or pTeleSignCustomerId="") then%>
<%=getMsg(395,"f time")%> <%=getMsg(396,"register")%> <%end if%>

<%=getMsg(397,"returning customer")%>
<%=getMsg(398,"email")%> <%if pStoreFrontDemoMode="-1" then%> <%else%> <%end if%> <%if pChargebackProtectionMerchant<>"0" and pChargebackProtectionMerchant<>"" then%> Click here to verify this seal <%end if%> <%if pSecureStoreGraph="-1" then%> Comersus Secure Store <%end if%>
<%=getMsg(399,"pass")%> <%if pStoreFrontDemoMode="-1" then%> <%else%> <%end if%> <%if pForgotPassword="-1" then%>
<%=getMsg(400,"forgot")%> <%end if%>
">  
 
<%end if%>

<%call closeDb()%>