$(function() {
	 
var ctrlPressed=0;
 
function mouseDown(e) {

	if (parseInt(navigator.appVersion)>3) {

		var evt = navigator.appName=="Netscape" ? e:event;

		if (navigator.appName=="Netscape" && parseInt(navigator.appVersion)==4) {
			// NETSCAPE 4 CODE
			var mString =(e.modifiers+32).toString(2).substring(3,6);
			ctrlPressed =(mString.charAt(1)=="1");
			self.status="modifiers="+e.modifiers+" ("+mString+")"
		} else {
			// NEWER BROWSERS [CROSS-PLATFORM]
			ctrlPressed =evt.ctrlKey;
			self.status=""
			+"ctrlKey=" +ctrlPressed 
		}

	}
	return true;
}

if (parseInt(navigator.appVersion)>3) {
	document.onmousedown = mouseDown;
if (navigator.appName=="Netscape") 
	document.captureEvents(Event.MOUSEDOWN);
}

	$(".nav li:not(.active)").click(function() {
		if(!ctrlPressed) {
			window.location=$(this).find("a").attr("href");
		}
	});
		  
		   
	$(".nav li:not(.active)").mouseenter(function() {
		$(this).css("cursor", "pointer");
		$(this).find("div:nth-child(3)").css("background", "url(/presentational/images/en_US/nav_bg.jpg) bottom right no-repeat");
		$(this).find("a").css("background", "url(/presentational/images/en_US/nav_bg_center.jpg) bottom repeat-x");
		$(this).find("a").css("color", "#FFF");
		$(this).find("div:nth-child(1)").css("background", "url(/presentational/images/en_US/nav_bg.jpg) bottom left no-repeat");

	}).mouseleave(function() {
		$(this).find("div:nth-child(1)").css("background", "url(/presentational/images/en_US/nav_bg.jpg) top left no-repeat");
		$(this).find("a").css("background", "url(/presentational/images/en_US/nav_bg_center.jpg) top repeat-x");
		$(this).find("a").css("color", "#000");
		$(this).find("div:nth-child(3)").css("background", "url(/presentational/images/en_US/nav_bg.jpg) top right no-repeat");
	});
	
	$(".contact_us_button").mouseenter(function() {
		$(this).css("background", "url(/presentational/images/en_US/contact_us_button.jpg) bottom repeat-x");
	}).mouseleave(function() {
		$(this).css("background", "url(/presentational/images/en_US/contact_us_button.jpg) top repeat-x");
	});
	
	$(".registration_button").mouseenter(function() {
		$(this).css("background", "url(/presentational/images/en_US/registration_button.gif) bottom repeat-x");
	}).mouseleave(function() {
		$(this).css("background", "url(/presentational/images/en_US/registration_button.gif) top repeat-x");
	});
	
	$(".forum_button_send").mouseenter(function() {
		$(this).css("background", "url(/presentational/images/en_US/forum_button_send.jpg) bottom repeat-x");
	}).mouseleave(function() {
		$(this).css("background", "url(/presentational/images/en_US/forum_button_send.jpg) top repeat-x");
	});
	
	$(".forum_tr_t1_1").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".forum_tr_t2_1").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".forum_tr_t2_1_1").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".forum_tr_t2_1_3").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".forum_tr_t2_1_4").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".userpage_forum_tr_t2_1").mouseenter(function() {
		$(this).css("background", "#dae2ec");
	}).mouseleave(function() {
		$(this).css("background", "#e9e9e9");
	});
	
	$(".p_nav li:not(.active)").mouseenter(function() {
		$(this).css("cursor", "pointer");
		$(this).find("div:nth-child(3)").css("background", "url(/presentational/images/en_US/p_nav_bg.jpg) bottom right no-repeat");
		$(this).find("a").css("background", "url(/presentational/images/en_US/p_nav_bg_center.jpg) bottom repeat-x");
		$(this).find("a").css("color", "#005470");
		$(this).find("div:nth-child(1)").css("background", "url(/presentational/images/en_US/p_nav_bg.jpg) bottom left no-repeat");

	}).mouseleave(function() {
		$(this).find("div:nth-child(1)").css("background", "url(/presentational/images/en_US/p_nav_bg.jpg) top left no-repeat");
		$(this).find("a").css("background", "url(/presentational/images/en_US/p_nav_bg_center.jpg) top repeat-x");
		$(this).find("a").css("color", "#FFF");
		$(this).find("div:nth-child(3)").css("background", "url(/presentational/images/en_US/p_nav_bg.jpg) top right no-repeat");
	});

});
