/*
	eventLogging.js
	
	@author: Cody Christofferson
	@since: 07.12.2007
	
	This javascript file is loaded into each page on the front end through
	the nav.templ file. When an event occurs that needs to be logged, the
	logEvent function is called. 

*/

function logEvent(statType,site,event,searchID,logData,rootPath){
		
	// I need to make sure the path has http:// in front of it
	var   subSection = rootPath.substring(4,0);
	if(subSection != "http"){
		rootPath = "http://" + rootPath;
	}
	 
	var url = rootPath +"/ajax/eventLogging.ajax.php?site="+site+"&statType="+statType+"&logData="+logData+"&searchID="+searchID+"&event="+event;
	//alert(url);
	var ajax = new Ajax.Updater("results", url,{evalScripts:true});
}