var switchacount = "0";
var switchbasket = "0";
var $normalbasketsize = 250;
var $count = 0;
var $hmbi = 0;


	function basketitems($count) {
		$hmbi = $count * 90;
		$normalbasketsize = $normalbasketsize + $hmbi;
	}
$(document).ready(function slideout() {
	var test_RightLogin_Email = 'Email oder Kundennr.';
	var test_RightLogin_Pwd = 'passwort';
	var searchparam = 'Suche...';
	var url= 'http://www.faxeshop.de';
	var myvalue;
	var myvaluenew;
	var myid;
	
	$('#head-account').click(function() {
		if (switchacount == "0") {
			$("#header_account").css("overflow","visible");
			$("#header_account").animate({height:'220px'},300);  
			$("#head-account img").attr('src',url+'/out/faxe/src/bg/closeslidedown.png')
			switchacount = "1";
		}
		else {
			$("#header_account").css("overflow","hidden");
			$("#header_account").animate({height:'97px'},300);
			$("#head-account img").attr('src',url+'/out/faxe/src/bg/openslidedown.png')
			switchacount = "0";
		}
	});
	
	$('#head-basket').click(function() {
		if (switchbasket == "0") {
			$("#header_basket").css("overflow","visible");
			$("#header_basket").animate({height:$normalbasketsize},300);  
			$("#head-basket img").attr('src',url+'/out/faxe/src/bg/closeslidedown.png')
			switchbasket = "1";
		}
		else {
			$("#header_basket").css("overflow","hidden");
			$("#header_basket").animate({height:'97px'},300);
			$("#head-basket img").attr('src',url+'/out/faxe/src/bg/openslidedown.png')
			switchbasket = "0";
		}
	});
	$('.ERROR_CLOSE').click(function() {
			$("#error_message").css("visibility","hidden");
			$(".error_box").css("visibility","hidden");
	});
	/*$('input[type=password]').focus(function() {
		myid = $(this).attr('id');
		myvalue = $(this).attr('value');
		$(this).attr('value','');
	}).blur(function() {
		myvaluenew = $('#'+myid).attr('value');
		if (myvaluenew == '') {
			$('#'+myid).attr('value', myvalue);
		}
	});
	
	$('input[type=text]').focus(function() {
		myid = $(this).attr('id');
		myvalue = $(this).attr('value');
		$(this).attr('value','');
	}).blur(function() {
		myvaluenew = $('#'+myid).attr('value');
		if (myvaluenew == '') {
			$('#'+myid).attr('value', myvalue);
		}
	});*/
	


	
	$('#test_OrderConfirmAGBTop').click(function() {
		if ( $('#test_OrderConfirmAGBTop').attr("checked") == true) {
			$('#test_OrderConfirmAGBBottom').attr("checked", "checked")
		}
		else {
				$('#test_OrderConfirmAGBBottom').attr("checked", "")
		}
	});
	
	$('#test_OrderConfirmAGBBottom').click(function() {
		if ( $('#test_OrderConfirmAGBBottom').attr("checked") == true) {
			$('#test_OrderConfirmAGBTop').attr("checked", "checked")
		}
		else {
				$('#test_OrderConfirmAGBTop').attr("checked", "")
		}
	});
	
	
	
});
