var AJAX_NAV_ENABLED = true;

function togglecontent(url) {
	/*if ($('page').style.top != '129px') {
		new Effect.Opacity('pagecontentwrapper', {to: 0, duration:0.5});
		new Effect.Opacity('wrap3', {to: 0, duration:0.5});
		new Effect.Opacity('wrap4', {to: 0, duration:0.5});
		setTimeout("new Effect.Morph('page', {style: 'opacity:0; top: 129px;', duration:0.5});", 500);
		setTimeout("content('"+url+"');", 1100);
	} else {
		content(url);
	}*/
	//content(url);
	
	if (AJAX_NAV_ENABLED) {
		return false;
	} else {
		return true;
	}
}

function content(url) {
	makePageRequest(url);
	urchinTracker(url);
	document.location.href='#'+url;
}

function makePageRequest(url, section) {
	new Ajax.Request(url, {method:'post', postBody:'url='+url, onSuccess:handlerPageFunc, onFailure:errFunc});
	setTimeout("if ($('page').style.top != '169px') { makePageRequest('"+url+"', '"+section+"') }", 2500);
}

var handlerPageFunc = function(t) {
	$('pagecontent').innerHTML = t.responseText;
}
//<!---<a href='/portfolio/ContentManagementSystems.cfm' onclick="return togglecontent(this.href);">download</a>--->
