| <SCRIPT>
// Catalog
Array // Price
Array associated with the respective items var name = price = quant = subtotal = ""; // declare variables var total = 0; /*************** Cookie Functions ***************/ var thisCookie = document.cookie; function getCookie(name) {var index = thisCookie.indexOf(name + "="); if (index == -1) return null; index = thisCookie.indexOf("=", index) + 1; var endstr = thisCookie.indexOf(";", index); if (endstr == -1) endstr = thisCookie.length; return unescape(thisCookie.substring(index, endstr));} function setCookie(name, quantity) {if (value != null && value != "") document.cookie = name + "=" + quantity; thisCookie = document. cookie;} function deleteCookie(name,
path, domain) { /*************** End of Cookie Functions ***************/ function getTotal()
{ // produces
the Total for the cart function updateCookie(item)
{ // if
the quantity is not a number give an alert & //
delete the item if the number is not greater than 0 or empty //
this causes the page to reload & rewrite the entire page with the
new information </SCRIPT> <FORM NAME="cart"> <TABLE BORDER="1" CELLPADDING="5" CELLSPACING="0"> <TR> <SCRIPT> var start = '<TR ALIGN="center"><TD
ALIGN="left">'; for (i = 0; i < Item.length;
i++) {
// total for
that particular item & subtotal for the table
document.write(start
+ name + column) document.write('<TR><TD
COLSPAN="3" ALIGN="right">'); </SCRIPT> </TABLE> </FORM> |