function equalHeight(group) {
		tallest = 0;
		group.each(function() {
			thisHeight = $(this).height();
			if(thisHeight > tallest) {
				tallest = thisHeight;
			}
		});
		group.height(tallest);
	}

function currentNav() {
	var currentUrl = window.location.pathname;
	var activeClass = "active";
	
	currentUrl = currentUrl.replace(/^\/+|\/+$/g, '') ; //trim / from beginning and end
	//console.log('currentUrl: ' + currentUrl);
	
	$('.nav a').each(function(){
		var thisHref = $(this).attr('href');
		thisHref = thisHref.replace(/^\/+|\/+$/g, '') ; //trim / from beginning and end
		thisHref == currentUrl ? $(this).addClass(activeClass) : false;
		//console.log('this: ' + thisHref);
		
	});
	
	$('.nav .' + activeClass).parent().parents('li').children('a').addClass(activeClass + '-parent active');
	$('.nav ul ul').hide();
	$('.nav .' + activeClass).each(function() {
		$(this).next('ul').show();
		});	
}

function updateRefresh(myPage, add)
{
	if (add == 1) {
		addPage = "add";
	} else {
		addPage  = "";
	}

	window.open("/update.asp?" + addPage + "page=" + myPage, "CURF_Update", "width=350,height=180,menubar=no,toolbar=no,status=no,scrollbars=yes,resizable=no");
}
