function show_content_from_sammy(id){
	this.name = id;
	this.selectednavid = "a#" + this.name;
	this.selectedcatcontent = "div#" + this.name;
	
/*
	console.log("id: " + id);
	console.log("selectednavid: " + selectednavid);
	console.log("selectedcatcontent: " + selectedcatcontent);
*/
	
	$('a.current').removeClass("current");
	$('div.collapsable').addClass("hidden").removeClass("current");

	$(this.selectednavid).addClass("current");
	$('div#' + id).removeClass("hidden").addClass("current");
	
	$('.category-' + id).removeClass("hidden").addClass("current");
}

//SAMMY

var app = $.sammy(function() {
	this.get('#/', function(context) {
/* 		context.log('Yo yo yo'); */
		$('#snav>a:not(a#initial-page)').removeClass("current");
		$('body.page-zs-20100321 #main>div:not(div#initial-page)').removeClass("current").addClass("hidden"); //had to add page template specific so that thinking, news, etc didn't get their content hidden -aaron
		$('div#initial-page').removeClass("hidden");
	});

	this.get('#/:id/', function(context) {	
		show_content_from_sammy(this.params['id']);
	});
});
  

//ENDSAMMY



//athena namespace object
athena = {};
// jQuery's onDOMready function
$(document).ready(function() {
	$('a[href="#"]').bind('click', function () {
		return false;
	});
/*
	$("#menu ul li").has('ul').first("a").html('hi');

*/

/*
    app.run('#/');
*/

});

athena.accordion = function(){
		$('.morelink').click(function() {
/*
			athena.scrollTo($(this));

*/			$(this).next('span').slideToggle(500);
				var htmlStr = $(this).children('span').html();
				var newHTML = htmlStr == '+' ? '&ndash;' : '+';
				$(this).children('span').html(newHTML);
			return false;1	
		}).next().hide();
}
/*
athena.setupAnchorSmoothScroll = function(){
	if(!athena.titleNav) return false;
	var titleLinks = $("#titleNav a");
	titleLinks.each( function( anIndex ){
		var targetId = this.href.substring( this.href.indexOf("#"), this.href.length );
		var target = $(targetId);
		$(this).bind( "click", target, function(e){
			athena.scrollTo( target );
			this.blur();
			return false;
		});
	});
}

*/
/*
athena.scrollTo = function( aTarget ){
	if( typeof document.body.style.maxHeight != "undefined"){
		$.scrollTo( aTarget, 550, { offset: { top: - athena.getNavPositionTop() } } );
	}else{
		$("#wrapper").scrollTo( aTarget, 550, { offset: { top: - athena.getNavPositionTop() } } );
	}	
}

*/

