function remove(pricing_id) { this.quick_cart.document.add_item.action.value = 'remove_item'; this.quick_cart.document.add_item.pricing_id.value = pricing_id; this.quick_cart.document.add_item.submit(); } function empty_cart() { var total_items = ; if (!total_items) confirm_msg = false; else if (total_items == 1) confirm_msg = "This will remove the item from your cart."; else if (total_items == 2) confirm_msg = "This will empty your cart of both your items."; else confirm_msg = "This will empty your cart of all "+total_items+" of your items."; if (confirm_msg) sure = confirm(confirm_msg+"\n\nAre you sure?"); if (sure) { this.quick_cart.document.add_item.action.value = 'reset_cart'; this.quick_cart.document.add_item.submit(); } } function view_cart() { this.window.location = 'http://www.webnetdeals.co.uk/?name=View+Cart&type=cart'; } function add_to_cart(item_id, pricing_id, qty) { if (qty == 'item_qty' && document.getElementById('item_qty')) { var qty = document.getElementById('item_qty'); qty = parseInt(qty.options[qty.selectedIndex].value); } // Add the item to the cart this.quick_cart.document.add_item.action.value = 'add_item'; this.quick_cart.document.add_item.stock_id.value = item_id; this.quick_cart.document.add_item.pricing_id.value = pricing_id; this.quick_cart.document.add_item.qty.value = qty; this.quick_cart.document.add_item.submit(); // Add one to the number of this item already in cart... var qty_in_cart = document.getElementById('qty_in_cart'); if (qty_in_cart) qty_in_cart.innerHTML = parseInt(qty_in_cart.innerHTML) + qty; // Show the item added window! GB_showCenter('Added Item!', 'http://www.webnetdeals.co.uk//added_item.php?stock_id='+item_id+'&pricing_id='+pricing_id, 480, 420); } function change_main_image(new_src) { document.getElementById('item_main_image').src = new_src; } function ask_question(stock_id) { GB_showCenter('Ask us a Question...', 'http://www.webnetdeals.co.uk//ask_question.php?stock_id='+stock_id, 480, 420); } sfHover = function() { var sfEls = document.getElementById("nav").getElementsByTagName("LI"); for (var i=0; i