 $(document).ready(function() {
$(".viewcart").click( function() { if ($("#cartcontents").is(":hidden")) {
        $("#cartcontents").slideDown("slow");
      } else {
        $("#cartcontents").slideUp("slow");} return false;} )  
		
		 		});

   $(document).ready(function() {
							  
							  $("#postcodecalc")
					.livequery('submit', function() { 
		$("#viewcartpostage").empty();
$(".viewcartpostage").addClass("loading");
var enteredpostcode =  $("#postcode").val();
var totalweight =  $("#weight").val();
var totalprice =  $("#totalprice").val();
var sessid = this.sessionId;
$(".viewcartpostage").load("jq-calculatepostage.php", {postcode: enteredpostcode, weight: totalweight, sid: sessid, total: totalprice}, function() {																						
$(".viewcartpostage").removeClass("loading"); 
} );return false;
 });
							  
	


		});
		

  
  
  $(document).ready(function() {
		$("#postcodecalcredo").submit( function() { 
		$("#viewcartpostage").empty();
$(".viewcartpostage").addClass("loading");
$("#reenterpostcode").slideUp("slow");
var enteredpostcode =  $("#postcoderedo").val();
var totalweight =  $("#weightredo").val();
var totalprice =  $("#totalpriceredo").val();
var countryselected =  $("#countryredo").val();
var sessid = this.sessionId;
$(".viewcartpostage").load("jq-calculatepostage.php", {postcode: enteredpostcode, weight: totalweight, sid: sessid, total: totalprice, country: countryselected }, function() {																						
$(".viewcartpostage").removeClass("loading"); 
} );return false;
 } ) ;


		});
  
  		var changepc = function() { if ($("#reenterpostcode").is(":hidden")) {
        $("#reenterpostcode").slideDown("slow");
      } else {
        $("#reenterpostcode").slideUp("slow");} return false;} ;
					
					
				$(".changepostcode")
					.livequery('click', changepc);