/***************************/
//@Author: Adrian "yEnS" Mato Gondelle
//@website: www.yensdesign.com
//@email: yensamg@gmail.com
//@license: Feel free to use it, but keep this credits please!					
/***************************/

//Load Black background overlap
function doOVERLAPBACKGROUND(func){
	if(func.toString() == "load"){		
		$("#backgroundPopup").css({
			"height": windowHeight ,
			"opacity": "0.7"
		});
		$("#backgroundPopup").fadeIn("slow");
	}else{
		$("#backgroundPopup").fadeOut("slow");
	}
}

//Load Ajax Loader
function doAJAXLOADER(func){
	if(func.toString() == "load"){
		var popupHeight = $("#ajaxLoader").height();
		var popupWidth = $("#ajaxLoader").width();
		$("#ajaxLoader").css({
			"position": "absolute",		
			"top": windowHeight/2-popupHeight/2,
			"left": windowWidth/2-popupWidth/2
		});
		$("#ajaxLoader").fadeIn("slow");
	}else{
		$("#ajaxLoader").fadeOut("slow");
	}
}