$(document).ready(function(){
	hideProfiles();
	$('ul.director_links a').click(function(){
		return showProfile($(this));
	});
	
	// if an anchor is passed in the url, highlight that profile:
	var path = document.location.toString();
	if (path.match('#')) {
		$("#" + path.split('#')[1]).show();
	}
});

function hideProfiles() {
	$("div.profile").hide();	
}

function showProfile(item) {
	id = item.attr('href').replace('#', '');
	hideProfiles();
	$("div.default").hide();
	$("#" + id).fadeIn("slow");
	return false;
}
