function showschool(school)
{
	hideschooldetails();
	if($('campus-details-' + school).visible())
	{
		new Effect.SlideUp('campus-details-' + school);
		//console.log('Sliding up ' + school);
	}
	else
	{
		//console.log('Sliding down ' + school);
		new Effect.SlideDown('campus-details-' + school, {afterFinish: function()
		{
			$('campus-details-' + school).down().style.bottom = '';
			//console.log('Afterfinish fired');
		}});
	}
}
var timers = [];
function showschoolname(school)
{
	if(typeof timers[school] != "undefined" && timers[school] != null)
	{
		clearTimeout(timers[school]);
	}
	if($('campus-name-' + school).visible())
	{
		$('campus-name-' + school).show();
		//console.log('keeping ' + school + ' visible');
	}
	else
	{
		new Effect.Appear('campus-name-' + school);
		//console.log('Makring ' + school + ' appear');
	}
}
function hideschoolname(school)
{
	timers[school] = setTimeout("dohideschoolname('" + school + "');", 1000);
}
function hideschooldetails()
{
	document.getElementsByClassName('campus-detail').each(function(el){
		//console.log("Found Element " + el.id);
		if(el.visible())
		{
			new Effect.SlideUp(el);
			//console.log('Sliding up ' + el.id);
		}
		else
		{
			el.hide();
			//console.log('Hiding element ' + el.id)
		}
	});
}
function dohideschoolname(school)
{
	//console.log(school + ' is off')
	new Effect.Fade('campus-name-' + school);
	timers[school] = null;
	//console.log('Hiding school ' + school);
}