function track_pdf_download(pdftitle, filepath) {
	_gaq.push(['_setAccount', 'UA-28160340-1']);
	_gaq.push(['_trackEvent', 'Downloads', pdftitle, filepath]);
	//_gaq.push(['_trackPageview', filepath]);
}



$(document).ready(function(){
	$('.submenu').each(function(){
		var targetheight = $(this).height()*1-20;
		$(this).find('.submenu_left').height(targetheight);
		$(this).find('.submenu_right').height(targetheight);
	});
	
	// Reset Font Size
	var originalFontSize = $('#mainbody p').not('#mainbody h2, #mainbody h3, #mainbody h4, #mainbody h5, #mainbody h6').css('font-size');
	
	$(".resetFont").click(function(){
		$('#mainbody').not('h2, h3, h4, h5, h6').namecss('font-size', originalFontSize);
	});
	// Increase Font Size
	$(".increaseFont").click(function(){
		var currentFontSize = $('#mainbody p').not('#mainbody h2, #mainbody h3, #mainbody h4, #mainbody h5, #mainbody h6').css('font-size');
		var currentFontSizeNum = parseFloat(currentFontSize, 10);
		var newFontSize = currentFontSizeNum*1.2;
		$('#mainbody').not('#mainbody h2, #mainbody h3, #mainbody h4, #mainbody h5, #mainbody h6').css('font-size', newFontSize);
		return false;
	});
	// Decrease Font Size
	$(".decreaseFont").click(function(){
		var currentFontSize = $('#mainbody p').not('#mainbody h2, #mainbody h3, #mainbody h4, #mainbody h5, #mainbody h6').css('font-size');
		var currentFontSizeNum = parseFloat(currentFontSize, 10);
		var newFontSize = currentFontSizeNum*0.8;
		$('#mainbody').not('#mainbody h2, #mainbody h3, #mainbody h4, #mainbody h5, #mainbody h6').css('font-size', newFontSize);
		return false;
	});
	
	
	$('a[href*="download.php"]').click(function(){
		var title = $(this).attr('title');
		var hrefstring = $(this).attr('href').split("?filepath=");
		var filepath = hrefstring[1].split('&filetitle=');
		var pdfpath = decodeURIComponent(filepath[0]);
		track_pdf_download(title, pdfpath);
	});
	
	 
});



