/**
 * Put any code you want to run on page load for _every_ page in the 
 * Eduction Centre in this function.
 */
function ftnGlobalOnLoad() {
	// Set the initial location of the menu selection marker
	ftnPositionMenuArrow(strSelectedMenuItemId);
	
	// Don't remove this - it calls the page level on load function
	ftnPageOnLoad();
}

/**
 * Locate the menu arrow under a menu item
 */
function ftnPositionMenuArrow(strCallingObjId) {
	// If no object id passed, reset to the current page
	if (strCallingObjId == undefined) strCallingObjId = strSelectedMenuItemId;
	
	// Get references to calling object and arrow
	objCalling = ftnGetObject(strCallingObjId);
	objArrow = ftnGetObject('menu-arrow');
	
	// Get location of calling object
	arrCallingLoc = ftnGetObjectPosition(objCalling);
	arrArrowLoc = ftnGetObjectPosition(objArrow);
	
	// Calculate position for arrow, directly under the centre of the
	// menu item
	var x = arrCallingLoc[0] + (ftnGetObjectWidth(objCalling)/2) - (ftnGetObjectWidth(objArrow)/2);
	
	// Set the new position - the arrow is positioned absolutely from the
	// body, so shouldn't need to worry about parent offset.
	ftnMoveObject(objArrow, x, arrArrowLoc[1]);
}