function msieversion()
{
	var ua = window.navigator.userAgent;
	var msie = ua.indexOf ( "MSIE " );
	
	if ( msie > 0 )      // If Internet Explorer, return version number
		return parseInt (ua.substring (msie+5, ua.indexOf (".", msie )));
	else                 // If another browser, return 0
		return 0;
}

function firefoxVersion()
{
	var ua = window.navigator.userAgent;
	var firefox = ua.indexOf ( "Firefox/" );
	
	if ( firefox > 0 )
		return parseInt (ua.substring (firefox+8, ua.indexOf (".", firefox )));
	else                 // If another browser, return 0
		return 0;
}

function FixNavigation(plNavigationHeight)
{
	var llTotalNavigationHeight;
	var ie = msieversion();
	var firefox = firefoxVersion();
	
	if ((ie > 0) && (ie < 7))
		return;
	
	if ((firefox > 0) && (firefox < 3))
		return;
		
	try
	{
		llTotalNavigationHeight = plNavigationHeight + 57 ;
		
		if (document.documentElement.clientHeight > llTotalNavigationHeight)
		{
			document.getElementById('gap1').style.position='fixed';
			document.getElementById('gap2').style.position='fixed';
			document.getElementById('navigationBackground').style.position='fixed';
			document.getElementById('navigation').style.position='fixed';
			document.getElementById('cse-search-box').style.position='fixed';
		}
	}
	catch(e)
	{
	}
}