// JavaScript Document$(document).ready(function(){/* ------------------------------------------------------	Common Functions------------------------------------------------------ */////	Auto Navigation Padding - for the lazy.	/*get the height and width*/	var navwid = $(".navigation").width();		/*get the ul's height and width*/	var navlistwi = $(".navigation ul").width();		/*figure the difference*/	var navWremain = (navwid)-(navlistwi);		/* Math! */	var totlinks = $(".navigation ul li").length;	var padWeach = Math.floor((navWremain) / (totlinks * 2)); if (padWeach <=0 ) {var padWeach = 0;}		/* Apply the padding we got from the Math */	//$(".navigation ul li a").css("padding","6px "+padWeach+"px");	////	Auto Navigation Highlighting	var url = location.href;	var lastSlash = url.lastIndexOf("/");	var firstQuestionMark = url.indexOf("?");	if(firstQuestionMark == -1) {firstQuestionMark = url.length;}	var filename = url.substring(lastSlash + 1, firstQuestionMark);		$(".navigation a").each(function(){		var addy = $(this).attr("href");		if (addy == filename){			$(this).addClass("current");			}	});//// Image Switcherfunction switcher(x, t){		$(x+" img").each(function(){		var imgeq = $(this).index();		var zindex = (-7) - (imgeq);		$(this).css("z-index", zindex);	}); 			var e = $(x+" img").length -1;	var ec = 0;	var f = (t) / (3);		setInterval(function(){				if (ec > e){ ec = 0; }				var prev = ec - (1);			if (prev < 0) { var prev = e;}						var fadeprev = $(x+" img").eq(prev);			var fadecurr = $(x+" img").eq(ec);						$(x+" img").eq(prev).fadeOut(f);			$(x+" img").eq(ec).fadeIn(f);						ec++;	 }, t);}//	activate the switchers, switcher(target, delay);//switcher("#backgrounds", 5000);/* ------------------------------------------------------	End Of File------------------------------------------------------ */});
