	
/* This code is to make menu float based on window scroll */
/* The menu will be scrolled vertically up and down */

var name = ".floatMenu";
var menuYloc = null;

$(document).ready(function(){
	
	//$(".floatMenu").draggable();
	
	menuYloc = parseInt($(name).css("top").substring(0,$(name).css("top").indexOf("px")))
	$(window).scroll(function () { 
		if($.browser.msie){
			var offset = menuYloc + $(document).scrollTop()+"px";
		}
		else{
			var offset = menuYloc + 50 * 1 + $(document).scrollTop()+"px";
		}
		$(name).animate({top:offset},{duration:300,queue:false});
	});
}); 

/* This function is to highlight the heading of a topic */
function goToLink(obj){
	$('SPAN.highlightSpan').removeClass("highlightSpan");
	$("#"+obj).addClass("highlightSpan");
}
