/*-------------------------------------------------------------------------------------------------
refreshCartWidget(qty):
qty = used to force a cart value

Only uses the qty variable on first press of add to card before a guest account has been used. 
Because can't grab the cookie right away, we manually push this qty to the cart 
-------------------------------------------------------------------------------------------------*/
function refreshCartWidget(qty) {
	
	document.getElementById("results_refreshCartWidget").style.display = "block";
	
	// If a qty wasn't passed (ie it was called from page load, not a buy now button, set to dont use
	if(qty == null) {
		qty = 'dontuse';
	}
	
	params     = new Array(); i = 0;
	params[i]  = "action=refreshCartWidget"; i++;	
	params[i]  = "qty=" + qty; i++;
	
	//  The results is put in the div that holds a text input created for each product by printCart
	putResults = "results_refreshCartWidget";	 
	 
	ajaxMagic('http://photojojo.com/store/cart/cart_ajax.php',params,putResults,'','doNotFade','doNotLoad'); 
	
	
	
}




