%@ Language=JavaScript%> <% %> <% ProductCode = String(Request("PCode")); if (Request.ServerVariables("REQUEST_METHOD") == "POST") { editCartFromRequest(); } else { if (ProductCode != null && ProductCode != "") { if (getCartQuantity(ProductCode) == 0) addToCart(ProductCode, 1); } } %> <% /* Connection Pooler */ var ConnectionCache = new ConnectionCache() /* server-side recordset */ var SCProduct = new Recordset("SCProduct", "GSProduct", "admin", "", "SELECT Product.ProductCode, Product.ProductName, Product.SuggestedRetailPrice, Product.ProductCategory, Product.ID, Product.Size FROM Product ORDER BY SortField", "ID", true, 2, 3, 3, ""); SCProduct_BeforeOpen(); SCProduct.Open(); SCProduct.ProcessAction(); SCProduct.SetMessages("",""); SCProduct_Server(); %> <% function SCProduct_Server() { // this function is in the Cycle server application // include file. order = processProductRSServer(SCProduct); // Stuff an ASP variable with the order in HTML. // display the quantities in edit boxes for subsequent // changes by the user. cartDisplay = order.formatAsHTML(true); // save the order. saveOrder(order); } function SCProduct_BeforeOpen() { SCProduct.Open = DSNLessRecordsetOpen SCProduct.filename = "GSProduct2.mdb" } %>