// Execute this after the site is loaded.
var $j = jQuery.noConflict();

$j.fn.tagName = function() {
    return this.get(0).tagName.toLowerCase();
}

$j(function() {
	// hide all categories
	$j("dd").hide();
	// show currently viewed category
	$j(".menu_current_year").show();
	$j(".menu_current_months").show();
	// update css background of currently viewed category to display correct arrow image
	$j(".menu_current_months").prev("dt").find("li").addClass('menu_current').addClass('menu_openli');
	
	$j(".menu_current_year ul li, .menu_year ul li").click(function(){
		if ($j(this).hasClass('menu_openli')){
		  $j(this).removeClass('menu_openli');
		  $j(this).parent().parent().next().hide();
		} else {
		  $j(this).addClass('menu_openli');
		  $j(this).parent().parent().next().show();
		}
	return false;
	});
});

