$(document).ready(function(){
	
	/*
	// external links
	$("a[@rel='external']").click(function() {
		return !window.open($(this).attr("href"));
	});*/
	
	// fade in messages
	$('.successMsg').hide();
	$('.successMsg').fadeIn(1000);
	$('.errorMsg div').hide();
	$('.errorMsg div').fadeIn(1000);
	$('.warningMsg').hide();
	$('.warningMsg').fadeIn(1000);
	
	// non-clickable links
	$(".return-false").click( function() {
		return false;
	});
	
	// captcha
	$("#captcha-block #reload").click( function() {
		return false;
	});
	
	// JUMP MENU
	$("select.jump-menu").change(function(x){
		var url = $("option:selected", this).attr("title");
		if (url.length) {
			window.location.href = url;
		}
	});
	
	$('.hide-with-js').hide(); // use this class to hide the message "please open this link in new window"
	
	
	// Catalogs Hover
	$("#catalog-listing li").hover( 
		function() {
			$(this).css("background-color", "#f1f1f1");
			$("img", this).css("border", "1px #01b6d1 solid");
		},
		function() {
			$(this).css("background-color", "transparent");
			$("img", this).css("border", "1px White solid");
		}
	);
	
	
	// Prodcuts Hover
	$("#product-listing li").hover( 
		function() {
			$("img.img-prod", this).css("border", "4px #01b6d1 solid");
			$("img.img-prod", this).css("padding", "0px");
		},
		function() {
			$("img.img-prod", this).css("border", "1px #ececec solid");
			$("img.img-prod", this).css("padding", "3px");
		}
	);
	
});
