//-- ShoppingCart JavaScript (other than "currency") by Daniel Giannascoli, Tallent Technolgy Corp, www.tallent.net

prodId00100desc = "Apple Cinnamon 8 oz. Loose"
prodId00101desc = "Assam 8 oz. Loose"
prodId00102desc = "Ceylon 8 oz. Loose"
prodId00103desc = "Chamomile 8 oz. Loose"
prodId00104desc = "Chinese Jasmine 8 oz. Loose"
prodId00105desc = "Chinese Keemum 8 oz. Loose"
prodId00106desc = "Cinnamint 8 oz. Loose"
prodId00107desc = "Cinnamon 8 oz. Loose"
prodId00108desc = "Darjeeling 8 oz. Loose"
prodId00109desc = "Dragonwell 8 oz. Loose"
prodId00110desc = "Earl Green 8 oz. Loose"
prodId00111desc = "Earl Grey 8 oz. Loose"
prodId00112desc = "Elderberry 8 oz. Loose"
prodId00113desc = "English Breakfast 8 oz. Loose"
prodId00115desc = "Fruit Ambrosia 8 oz. Loose"
prodId00116desc = "Gertrude's Gold Reserve 8 oz. Loose"
prodId00118desc = "Greenberry 8 oz. Loose"
prodId00119desc = "Greenilla 8 oz. Loose"
prodId00120desc = "Gunpowder 8 oz. Loose"
prodId00121desc = "Hamilton 8 oz. Loose"
prodId00122desc = "Holiday 8 oz. Loose"
prodId00123desc = "Ice Tea Sampler 10 1 oz. Packets"
prodId00124desc = "Lemon 8 oz. Loose"
prodId00125desc = "Lemon Cooler 8 oz. Loose"
prodId00126desc = "Mango 8 oz. Loose"
prodId00127desc = "O'Neil's Irish Breakfast 8 oz. Loose"
prodId00128desc = "Oolong 8 oz. Loose"
prodId00129desc = "Orange Pekoe 8 oz. Loose"
prodId00130desc = "Orange Spice 8 oz. Loose"
prodId00131desc = "Peppermint 8 oz. Loose"
prodId00132desc = "Raspberry 8 oz. Loose"
prodId00133desc = "Russian Caravan 8 oz. Loose"
prodId00134desc = "Vanilla 8 oz. Loose"
prodId00135desc = "Wild Cherry 8 oz. Loose"
prodId00136desc = "Vassar Blend 8 oz. Loose"
prodId00137desc = "Royal Blend 8 oz. Loose"
prodId00138desc = "Strawberry/Kiwi 8 oz. Loose"
prodId00139desc = "Summer Delight 8 oz. Loose"
prodId00200desc = "Apple Cinnamon 50 CT. Teaball"
prodId00201desc = "Assam 50 CT. Teaball"
prodId00202desc = "Ceylon 50 CT. Teaball"
prodId00203desc = "Chamomile 50 CT. Teaball"
prodId00204desc = "Chinese Jasmine 50 CT. Teaball"
prodId00205desc = "Chinese Keemum 50 CT. Teaball"
prodId00206desc = "Cinnamint 50 CT. Teaball"
prodId00207desc = "Cinnamon 50 CT. Teaball"
prodId00208desc = "Darjeeling 50 CT. Teaball"
prodId00209desc = "Dragonwell 50 CT. Teaball"
prodId00210desc = "Earl Green 50 CT. Teaball"
prodId00211desc = "Earl Grey 50 CT. Teaball"
prodId00212desc = "Elderberry 50 CT. Teaball"
prodId00213desc = "English Breakfast 50 CT. Teaball"
prodId00214desc = "Fruit Ambrosia 50 CT. Teaball"
prodId00215desc = "Greenberry 50 CT. Teaball"
prodId00216desc = "Greenilla 50 CT. Teaball"
prodId00217desc = "Gunpowder 50 CT. Teaball"
prodId00218desc = "Hamilton 50 CT. Teaball"
prodId00219desc = "Holiday 50 CT. Teaball"
prodId00220desc = "Lemon 50 CT. Teaball"
prodId00221desc = "Lemon Cooler 50 CT. Teaball"
prodId00222desc = "Mango 50 CT. Teaball"
prodId00223desc = "O'Neil's Irish Breakfast 50 CT. Teaball"
prodId00224desc = "Oolong 50 CT. Teaball"
prodId00225desc = "Orange Pekoe 50 CT. Teaball"
prodId00226desc = "Orange Spice 50 CT. Teaball"
prodId00227desc = "Peppermint 50 CT. Teaball"
prodId00228desc = "Raspberry 50 CT. Teaball"
prodId00229desc = "Russian Caravan 50 CT. Teaball"
prodId00230desc = "Vanilla 50 CT. Teaball"
prodId00231desc = "Wild Cherry 50 CT. Teaball"
prodId00232desc = "Ford Sampler 32 Packets (2 each, 16 blends)"
prodId00233desc = "Green Tea Sampler 36 Packets (6 each, 5 blends)"
prodId00300desc = "Caffeine Free Sampler 30 Packets (6 each, 5 blends)"
prodId00400desc = "Darjeeling De-Caf 8 oz. Loose"
prodId00401desc = "Earl Grey De-Caf 8 oz. Loose"
prodId00402desc = "Orange Pekoe De-Caf 8 oz. Loose"
prodId00500desc = "Darjeeling De-Caf 50 CT. Teaball"
prodId00501desc = "Earl Grey De-Caf 50 CT. Teaball"
prodId00502desc = "Orange Pekoe De-Caf 50 CT. Teaball"
prodId00600desc = "Super Sampler 62 Teaballs (2 each, 31 blends)"
prodId00700desc = "Apple Cinnamon 100 CT. Teaball"
prodId00701desc = "Assam 100 CT. Teaball"
prodId00702desc = "Ceylon 100 CT. Teaball"
prodId00703desc = "Chamomile 100 CT. Teaball"
prodId00704desc = "Chinese Jasmine 100 CT. Teaball"
prodId00705desc = "Chinese Keemum 100 CT. Teaball"
prodId00706desc = "Cinnamint 100 CT. Teaball"
prodId00707desc = "Cinnamon 100 CT. Teaball"
prodId00708desc = "Darjeeling 100 CT. Teaball"
prodId00709desc = "Dragonwell 100 CT. Teaball"
prodId00710desc = "Earl Green 100 CT. Teaball"
prodId00711desc = "Earl Grey 100 CT. Teaball"
prodId00712desc = "Elderberry 100 CT. Teaball"
prodId00713desc = "English Breakfast 100 CT. Teaball"
prodId00714desc = "Fruit Ambrosia 100 CT. Teaball"
prodId00715desc = "Greenberry 100 CT. Teaball"
prodId00716desc = "Greenilla 100 CT. Teaball"
prodId00717desc = "Gunpowder 100 CT. Teaball"
prodId00718desc = "Hamilton 100 CT. Teaball"
prodId00719desc = "Holiday 100 CT. Teaball"
prodId00720desc = "Lemon 100 CT. Teaball"
prodId00721desc = "Lemon Cooler 100 CT. Teaball"
prodId00722desc = "Mango 100 CT. Teaball"
prodId00723desc = "O'Neil's Irish Breakfast 100 CT. Teaball"
prodId00724desc = "Oolong 100 CT. Teaball"
prodId00725desc = "Orange Pekoe 100 CT. Teaball"
prodId00726desc = "Orange Spice 100 CT. Teaball"
prodId00727desc = "Peppermint 100 CT. Teaball"
prodId00728desc = "Raspberry 100 CT. Teaball"
prodId00729desc = "Russian Caravan 100 CT. Teaball"
prodId00730desc = "Vanilla 100 CT. Teaball"
prodId00731desc = "Wild Cherry 100 CT. Teaball"
prodId00800desc = "Darjeeling De-Caf 100 CT. Teaball"
prodId00801desc = "Earl Grey De-Caf 100 CT. Teaball"
prodId00802desc = "Orange Pekoe De-Caf 100 CT. Teaball"
prodId00900desc = "Gertrude's Gold Reserve 50 1 oz. Packets"
prodId00901desc = "Greenberry 50 1 oz. Packets"
prodId00902desc = "Mango 50 1 oz. Packets"
prodId00903desc = "Raspberry 50 1 oz. Packets"
prodId00904desc = "Royal Blend 50 1 oz. Packets"
prodId00905desc = "Strawberry/Kiwi 50 2 oz. Packets"
prodId00906desc = "Summer Delight 50 1 oz. Packets"
prodId00907desc = "Vassar Blend 50 1 oz. Packets"
prodId01000desc = "Gertrude's Gold Reserve 100 1 oz. Packets"
prodId01001desc = "Greenberry 100 1 oz. Packets"
prodId01002desc = "Mango 100 1 oz. Packets"
prodId01003desc = "Raspberry 100 1 oz. Packets"
prodId01004desc = "Royal Blend 100 1 oz. Packets"
prodId01005desc = "Strawberry/Kiwi 100 2 oz. Packets"
prodId01006desc = "Summer Delight 100 1 oz. Packets"
prodId01007desc = "Vassar Blend 100 1 oz. Packets"
prodId01100desc = "G.H. Ford Signature Sampler in a Tin (2 each, 16 blends)"


//-- JavaScript code written by Alan Simpson - www.coolnerds.com
function currency(anynum) {
   //-- Returns passed number as string in $xxx,xxx.xx format.
   anynum=eval(anynum)
   workNum=Math.abs((Math.round(anynum*100)/100));workStr=""+workNum
   if (workStr.indexOf(".")==-1){workStr+=".00"}
   dStr=workStr.substr(0,workStr.indexOf("."));dNum=dStr-0
   pStr=workStr.substr(workStr.indexOf("."))
   while (pStr.length<3){pStr+="0"}

   //--- Adds comma in thousands place.
   if (dNum>=1000) {
      dLen=dStr.length
      dStr=parseInt(""+(dNum/1000))+","+dStr.substring(dLen-3,dLen)
   }

   //-- Adds comma in millions place.
   if (dNum>=1000000) {
      dLen=dStr.length
      dStr=parseInt(""+(dNum/1000000))+","+dStr.substring(dLen-7,dLen)
   }
   retval = dStr + pStr 
   //-- Put numbers in parentheses if negative.
   if (anynum<0) {retval="("+retval+")"}
   return "$"+retval
}

function price(WORK) {
	if ([WORK] >= "prodId00100" && [WORK] < "prodId00200")  {
		prodPrice = 15.50
	}
	if ([WORK] >= "prodId00200" && [WORK] < "prodId00300")  {
		prodPrice = 15.50
	}
	if ([WORK] >= "prodId00300" && [WORK] < "prodId00400")  {
		prodPrice = 15.95
	}
	if ([WORK] >= "prodId00400" && [WORK] < "prodId00500")  {
		prodPrice = 17.50
	}
	if ([WORK] >= "prodId00500" && [WORK] < "prodId00600")  {
		prodPrice = 18.95
	}
	if ([WORK] >= "prodId00600" && [WORK] < "prodId00700")  {
		prodPrice = 22.95
	}
	if ([WORK] >= "prodId00700" && [WORK] < "prodId00800")  {
		prodPrice = 24.95
	}
	if ([WORK] >= "prodId00800" && [WORK] < "prodId00900")  {
		prodPrice = 37.50
	}
	if ([WORK] >= "prodId00900" && [WORK] < "prodId01000")  {
		prodPrice = 74.95
	}
	if ([WORK] >= "prodId01000" && [WORK] < "prodId01100")  {
		prodPrice = 124.95
	}
	if ([WORK] >= "prodId01100" && [WORK] < "prodId01200")  {
		prodPrice = 16.95
	}
}

function listCart() {
	if (document.cookie != "")  {
		prodShipping = 0
		subTotal = 0

		document.write("<form name=\"checkingOut\"><table border=\"0\" cellpadding=\"0\" cellspacing=\"5\" width=\"100%\">")
		thisCookie = document.cookie.split("; ")
		document.write("<tr><td class=\"subtopic\">Product<\/td><td class=\"subtopic\" align=\"right\">Price<\/td><td class=\"subtopic\" align=\"right\">Quantity<\/td><td class=\"subtopic\" align=\"right\">Extended<\/td><td><input type=\"button\" value=\"Empty Your Cart\" onclick=\"emptyCart()\"><\/td><\/tr>")
	  	    for (i=0; i<thisCookie.length; i++) {
				prodId = thisCookie[i].split("=")[0]
				num = thisCookie[i].split("=")[1]
				price(prodId)
				prodExtended = eval(prodPrice * num)
				subTotal = subTotal + prodExtended
				document.write("<tr><td>" + eval(prodId + "desc") + "<\/td>")
				document.write("<td align=\"right\">" + currency(prodPrice) + "<\/td>")
				document.write("<td align=\"right\">" + eval(num) + "<\/td>")
				document.write("<td align=\"right\">" + currency(prodExtended) + "<\/td>")
				document.write("<td><input type=\"button\" name=\"delete\"" + prodId + " value=\"Remove Item\" onclick=\"shelf(\'" + prodId + "\')\"><\/td><\/tr>")
			}
			if ([subTotal] > 0 && [subTotal] < 18.99)  {
				prodShipping = 6
			}
			if ([subTotal] >= 18.99 && [subTotal] < 29.99)  {
				prodShipping = 7
			}
			if ([subTotal] >= 29.99 && [subTotal] < 39.99)  {
				prodShipping = 8
			}
			if ([subTotal] >= 39.99 && [subTotal] < 49.99)  {
				prodShipping = 9
			}
			if ([subTotal] >= 49.99 && [subTotal] < 69.99)  {
				prodShipping = 10
			}
			if ([subTotal] >= 59.99)  {
				prodShipping = 12
			}

		grandTotal = subTotal + prodShipping
		document.write("<tr><td><\/td><td><\/td><td align=\"right\">Sub Total<\/td><td align=\"right\"> " + currency(subTotal) + "<\/td><td><\/td><\/tr>")
		document.write("<tr><td><\/td><td><\/td><td align=\"right\">\+ Shipping<\/td><td align=\"right\"> " + currency(prodShipping) + "<\/td><td><\/td><\/tr>")
		document.write("<tr><td><\/td><td><\/td><td align=\"right\">Total Order<\/td><td align=\"right\"> " + currency(grandTotal) + "<\/td><td><input type=\"button\" value=\"Check Out\" onclick=\"checkOut()\"><\/td><\/tr>")
		document.write("<\/table><\/form>")
			if ([subTotal] > 99.99)  {
				document.write("<p>note: orders over $100.00 are subject to variable shipping charges<\/p>")
			}
		document.write("")
	} else {
		document.write("<p class=\"subtopic\">Your cart is empty. Please make a selection from our online Product Catalog<\/p>")
	}
	if (document.referrer != "") {
	document.write("<div align=\"right\"><p class=\"subtopic\"><a href=\"" + document.referrer + "\">Back to Previous Page<\/a><\/div>")
	}
	document.write("<div align=\"right\"><p class=\"subtopic\"><a href=\"product.htm\">Back to Product Catalog Index<\/a><\/div>")

}


function add(prodId) {
	var num = document.myForm.elements["num" + prodId].value;
		if (num < 1) {
			num = 1
		}
	expireDate = new Date
	expireDate.setDate(expireDate.getDate()+1)
	setCookie("prodId"+prodId,num,expireDate,"/");
		if (document.cookie == "") {
			alert("In order to add items to your cart, your browser must be set to receive cookies from our server.  Please refer to your browser\'s \"preferences\"")
		} else {
			alert("The item has been added to your cart")
		}
} 	


function setCookie (name,value,expires,path) {
	document.cookie = name + "=" + escape (value) +
    ((expires) ? "; expires=" + expires.toGMTString() : "") +
    ((path) ? "; path=" + path : "");
}



function shelf(prodId) {
	if (confirm("Do you really want to delete this item?")) {
		var num = 0
		expireDate = new Date
		expireDate.setDate(expireDate.getDate()-1)
		delCookie(prodId,num,expireDate,"/");
		alert("The item has been removed from your cart")
		top.location.href = top.location
	}
}

function delCookie (name,value,expires,path) {
	document.cookie = name + "=" + escape (value) +
    ((expires) ? "; expires=" + expires.toGMTString() : "") +
    ((path) ? "; path=" + path : "");
}


function emptyCart() {
	if (document.cookie != "") {
  	 	if (confirm("Do you really want to empty your cart?")) {
    		thisCookie = document.cookie.split("; ")
    	    expireDate = new Date
    		expireDate.setDate(expireDate.getDate()-1)
                               
    	    for (i=0; i<thisCookie.length; i++) {
    	        cookieName = thisCookie[i].split("=")[0]
    	        document.cookie = cookieName + "=-1;expires=" + expireDate.toGMTString() + "; path=/"
    	    }
    	    alert("Number of items removed: " + thisCookie.length + ".  Your cart is empty.")
			top.location.href = top.location
        }
    }
}

function fillForm() {
    thisCookie = document.cookie.split("; ")
	lineItem = 0
	prodShipping = 0
	subTotal = 0
	document.write("<form method=\"POST\" name=\"shippingBilling\" action=\"gdform.php\">")
	document.write("<input type=\"hidden\" value=\"ghfordtea\@cs.com\" name=\"recipient\">")
	document.write("<input type=\"hidden\" value=\"ghfordtea\@cs.com\" name=\"email\">")
		for (i=0; i<thisCookie.length; i++) {
			prodId = thisCookie[i].split("=")[0]
			num = thisCookie[i].split("=")[1]
			price(prodId)
			prodExtended = eval(prodPrice * num)
			subTotal = subTotal + prodExtended
			lineItem++
			document.write("<input type=\"hidden\" value=\"" + prodId + "\" name=\"" + [lineItem + "_web_code"] + "\">")
			document.write("<input type=\"hidden\" value=\"" + eval(prodId + "desc") + "\" name=\"" + [lineItem + "_product"] + "\">")
			document.write("<input type=\"hidden\" value=\"" + currency(prodPrice) + "\" name=" + [lineItem + "_price"] + "\">")
			document.write("<input type=\"hidden\" value=\"" + eval(num) + "\" name=" + [lineItem + "_quantity"] + "\">")
			document.write("<input type=\"hidden\" value=\"" + currency(prodExtended) + "\" name=" + [lineItem + "_extended_price"] + "\">")
		}
		if ([subTotal] > 0 && [subTotal] < 18.99)  {
			prodShipping = 6
		}
		if ([subTotal] >= 18.99 && [subTotal] < 29.99)  {
			prodShipping = 7
		}
		if ([subTotal] >= 29.99 && [subTotal] < 39.99)  {
			prodShipping = 8
		}
		if ([subTotal] >= 39.99 && [subTotal] < 49.99)  {
			prodShipping = 9
		}
		if ([subTotal] >= 49.99 && [subTotal] < 69.99)  {
			prodShipping = 10
		}
		if ([subTotal] >= 59.99)  {
			prodShipping = 12
		}
		grandTotal = subTotal + prodShipping
	document.write("<input type=\"hidden\" value=\"" + currency(subTotal) + "\" name=" + [lineItem + "_sub_total_price"] + "\">")
	document.write("<input type=\"hidden\" value=\"" + currency(prodShipping) + "\" name=" + [lineItem + "_shipping_price"] + "\">")
	document.write("<input type=\"hidden\" value=\"" + currency(grandTotal) + "\" name=" + [lineItem + "_grand_total_price"] + "\">")
	document.write("<input type=\"hidden\" value=\"http:\/\/www.ghfordtea.com\/product.htm\" name=\"redirect\">")
	document.write("<input type=\"hidden\" value=\"HTTP_USER_AGENT\" name=\"env_report\">")
	document.write("<table border=\"0\" cellpadding=\"10\" cellspacing=\"0\" width=\"100%\">")
	document.write("<tr>")
	document.write("<td><p>Billing Information<\/p>")
	document.write("<p>Name:<br>")
	document.write("<input name=\"billto_name\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Address1:<br>")
	document.write("<input name=\"billto_address1\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Address2:<br>")
	document.write("<input name=\"billto_address2\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>City:<br>")
	document.write("<input name=\"billto_city\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>State: <input name=\"billto_state\" size=\"2\" type=\"text\"> Zip Code: <input name=\"zipcode\" size=\"10\" type=\"text\"> Country: <input name=\"country\" size=\"5\" type=\"text\"><\/p>")
	document.write("<p>E-mail:<br>")
	document.write("<input name=\"billto_email\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Phone:<br>")
	document.write("<input name=\"billto_phone\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Please select a payment option for your purchase?<\/p>")
	document.write("<p><input checked name=\"paytype\" type=\"radio\" value=\"ccard\">Charge card (please enter number and type below)<br>")
	document.write("<\/p>")
	document.write("<ul>")
	document.write("<ol>")
	document.write("<li>Name as it appears on the Charge card:<br>")
	document.write("<input name=\"cc_name\" size=\"35\" type=\"text\">")
	document.write("<li>Charge card number:<br>")
	document.write("<input name=\"cc_num\" size=\"25\" type=\"text\">")
	document.write("<li>Expiration date:<br>")
	document.write("<input name=\"cc_expdt\" size=\"8\" type=\"text\"><br>")
	document.write("<li>Card Type: <input checked name=\"cc_type\" type=\"radio\" value=\"visa\">Visa <input name=\"cc_type\" type=\"radio\" value=\"mastcard\">Master Card <input name=\"cc_type\" type=\"radio\" value=\"amex\">American Express")
	document.write("<\/ol>")
	document.write("<\/ul>")
	document.write("<p><input name=\"paytype\" type=\"radio\" value=\"callus\">Call us at 845-298-8900<br>")
	document.write("<br>")
	document.write("<input name=\"paytype\" type=\"radio\" value=\"callme\">Please call me at the number below<\/p>")
	document.write("<dl>")
	document.write("<dd>Phone number <input name=\"dtphone\" size=\"15\" type=\"text\"> where we can<br>")
	document.write("reach you between 9am-5pm eastern time US.")
	document.write("<\/dl>")
	document.write("<p>Please give us any comments you may have about your order or our Web Site:<\/p>")
	document.write("<p><textarea name=\"comment\" rows=\"6\" cols=\"53\"><\/textarea><br>")
	document.write("<\/p>")
	document.write("<p>")
	document.write("<hr>")
	document.write("<\/p>")
	document.write("<p>Shipping Information<\/p>")
	document.write("<p>If the shipping address is different than your billing address, please specify where you would like us to ship your purchase<\/p>")
	document.write("<p>If this is a gift order, please include the delivery address and special instructions, if any.<\/p>")
	document.write("<p>Name:<br>")
	document.write("<input name=\"stname\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Address 1:<br>")
	document.write("<input name=\"staddress1\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>Address 2:<br>")
	document.write("<input name=\"staddress2\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>City:<br>")
	document.write("<input name=\"stcity\" size=\"53\" type=\"text\"><\/p>")
	document.write("<p>State: <input name=\"ststate\" size=\"2\" type=\"text\"> Zip Code: <input name=\"mlzipcode\" size=\"10\" type=\"text\"> Country: <input name=\"mlcountry\" size=\"5\" type=\"text\"><br>")
	document.write("<\/p>")
	document.write("<p>")
	document.write("<hr>")
	document.write("Submit your order<\/p>")
	document.write("<p>Please make sure you have<\/p>")
	document.write("<ol>")
	document.write("<li>Reviewed your order")
	document.write("<li>Completed the billing information")
	document.write("<li>Completed the shipping information, if applicable")
	document.write("<\/ol>")
	document.write("<p>We do our best to ship an order within 7 to 10 business days of it being processed, sometimes delays might occur and we appreciate your understanding.<br>")
	document.write("Please select <input type=\"submit\" value=\"SUBMIT AND PROCESS ORDER\" onclick=\"processOut()\"> to submit your purchase, or")
	document.write("<input type=\"reset\" value=\"RESET\"> to delete all entered information and start over.<\/p><\/td>")
	document.write("<\/tr>")
	document.write("<\/table>")
	document.write("<\/form>")
}

function checkOut() {
	top.location.href = "process.htm"
}

function processOut() {
	document.shippingBilling.submit()
	if (document.cookie != "") {
		thisCookie = document.cookie.split("; ")
    	expireDate = new Date
    	expireDate.setDate(expireDate.getDate()-1)
                               
    	for (i=0; i<thisCookie.length; i++) {
    		cookieName = thisCookie[i].split("=")[0]
  		  	document.cookie = cookieName + "=-1;expires=" + expireDate.toGMTString() + "; path=/"
		}
    	alert("Thank You for Your Order")
		//top.location.href = "http://www.ghfordtea.com/product.htm"
	}
}
