$(document).ready(function(){

	$("#guid ul, #guid .ph").hover(
		function(){
			$(this).parent().find("ul").attr("class","on");

			$(this).parent().find("img").each(function( i ) {
				$(this).hide();
//				$(this).stop(false, true).fadeOut();
            });

		},
		function(){
			$(this).parent().find("ul").attr("class","off");

			$(this).parent().find("img").each(function() {
				$(this).show();
//				$(this).stop(false, true).fadeIn();
            });

		}
	);
	$("#guid ul, #guid .ph").mouseup(
		function(){
			$(this).parent().find("ul").attr("class","on");

			$(this).parent().find("img").each(function( i ) {
				$(this).hide();
//				$(this).stop(false, true).fadeOut();
            });
		}
	);

	$("#globalNavi a img").hover(
		function(){
			$(this).stop(false, true).fadeTo("slow",0);
		},
		function(){
			$(this).stop(false, true).fadeTo("slow",1);
		}
	);
	$("#globalNavi a img").mouseup(
		function(){
			$(this).stop(false, true).fadeTo("slow",1);
		}
	);



	$(".hovImg, #globalFooter .nav img").hover(
		function(){
			this.src = this.src.replace('off.','on.');
		},
		function(){
			this.src = this.src.replace('on.','off.');
		}
	);

	$(".newWindow").click(
		function(){
			window.open(this.href); return false;
		}
	);

	$(".backBtn").click(
		function(){
			history.back(); return false;
		}
	);

	$(".topBtn").click(
		function(){
			$("html,body").animate({ scrollTop: 0 }, 500); return false;
		}
	);


});


