function koszyk_dodaj() {
	ilosc=parseInt($(this).parents("div.shop_item").find(".product_count").val());
	numer=parseInt($(this).parents("div.shop_item").find(".product_id").val());
	typ=$(this).parents("div.shop_item").find(".product_type").val();
	
	$("#basketItemsWrap ul").remove();
	$("#slidingTopFooter #total_price").html("<center>Toegevoegd aan winkelmandje...</center>");
	
	$.post("/ajax.php5",{opcja : "cart_add", numer : numer, ilosc : ilosc, typ: typ}, function (data) {
		$.post("/ajax.php5",{opcja: "cart"}, function(data) {
			$("#cart_box").html(data); 
			$("#slidingTopTrigger").html('<img alt="Verberg boodschappenlijst" src="/img/cart_arrow_close.png"/><span>Verberg boodschappenlijst</span>');
		});
	});
	return false;
}

function reorder(id) {	
	$("#basketItemsWrap ul").remove();
	$("#slidingTopFooter #total_price").html("<center>Toegevoegd aan winkelmandje...</center>");
	
	$.post("/ajax.php5",{opcja : "cart_duplicate", numer : id}, function (data) {
		window.location='/winkelmandje/';
	});
	return false;
}

function basket_delete() {
	numer=parseInt($(this).parents("li.cart_item").find(".product_id").val());
	typ=$(this).parents("li.cart_item").find(".product_type").val();
	
	$("#basketItemsWrap ul").remove();
	$("#slidingTopFooter #total_price").html("<center>Verwijderd uit winkelmandje...</center>");
	
	$.post("/ajax.php5",{opcja : "cart_delete", numer : numer, typ: typ}, function (data) {
		$.post("/ajax.php5",{opcja: "cart"}, function(data) {
			$("#cart_box").html(data); 
			$("#slidingTopTrigger").html('<img alt="Verberg boodschappenlijst" src="/img/cart_arrow_close.png"/><span>Verberg boodschappenlijst</span>');
		});
	});
	return false;
}

function show_long_item() {
	element=$(this).parents("li.cart_item");
	$(element).find(".cart_price,.cart_delete,.item").hide();
	$(element).find(".item_long").show();
}

function hide_long_item() {
	element=$(this).parents("li.cart_item");
	$(element).find(".item_long").hide();
	$(element).find(".cart_price,.cart_delete,.item").show();
}