// American Floral Delivery Javascript Library

	$(document).ready(function() {
		
		// Remove Promo Not Found Banners
		$("#Table15:contains('code is not found')").remove();
		
		// Dropdown Arrows
		$("ul.top_section").parent("li").css("background-image", "url(/Skins/769/images/arrow.png)");
		
		// Removes titles from anchor tags that contain the state abbreviation MI
		$("a[title*='MI']").removeAttr('title');

		// PDP 
		if(s.prop11=="Product Details"){
			// Graphic Adds and Upgrade Text Removal
			$("#product-price-text p").remove();
			$("#product-price-text center").append("<img src='/Skins/769/graphics/business2.gif' alt='Better Business Bureau Accredited'>");
			// Automatically checks the last (highest) price point
			$('.step-content .price	.priceselect input:last').attr('checked','checked');	
		}
			//Picks the highest price on the Deal of the Day page
			if(s.pageName=="Product Details: CHOICE"){
				$('.step-content #tfpricetable .pricebutton	input:last').attr('checked','checked');	
			}
	
	// Checkout scripts
	
		// Delivery Page - Remove prices and replace with graphic
		if(s.pageName=="Checkout: Delivery"){
			$("td.shopcart-VIEW10:contains('$')").css("display","none");
			$("#Table34").css("display","none");
			$("table#Table19 tr .shopcart-VIEW10 #Table11").addClass("ProductToKeep");
			$(".ProductToKeep").css("text-align","center");
			$(".ProductToKeep").css("padding-top","10px");
			$(".ProductToKeep td[width=5]").remove();
			$(".ProductToKeep td[width=150]").attr("width","240");
			$(".ProductToKeep").append("<br><img src='/Skins/769/graphics/secure3eflorist.png' alt='Join Over 1 Million Satisfied Customers'>");
			$("#Table19 table").not(".ProductToKeep").remove();
			$("table#Table26").remove();
		}
		
		// Payment Page - Change price colors and change tax to HC
		if(s.pageName=="Checkout: Billing"){
			$("td:contains('$')").css("color","#b3b5b1");
			$("td a strong:contains('$')").css("color","#b3b5b1");
	//		$('#Table20 td:contains("Tax")').text("6% H.C.");
		}
		
		// Confirmation Page - change tax to HC and remove the bottom tax section
		if(s.pageName=="Checkout: Order Confirmation"){
	//		$("td.shopcart-VIEW9:contains('Tax')").text("6% H.C.");
			$(".shopcart-VIEW9:contains('Total includes both')").remove();
		}
			
	});
