	function isIE()  // is browser IE?
	  {
	  if (navigator.appName == "Microsoft Internet Explorer")
	    return true;
	  else
	    return false;
	  }
	
	function isNetscape() // is browser NS?
	{
		if (navigator.appName == "Netscape")
			return true ;
		else
			return false ;	
	}
	function isWin()  // is browser OS Windows?
	  {
	  if (navigator.platform.indexOf("Win") >= 0)
	    return true;
	  else
	    return false;
	  }

	function getBrowserVer()  // get the browser version
	  {
	  if (navigator.appVersion == null || navigator.appVersion == "")
	    return "n/a";
	  // fix for IE 5.x appVersion bug, which returns 4.x instead of 5.x
	  if (isIE() && navigator.userAgent.indexOf("5.") != -1)
	    { 
	    var verNum = "";
	    var str = navigator.userAgent;
	    var pos = str.indexOf("IE ");  // real version num follows "IE "
	    for (pos=pos+3; pos<str.length; pos++)  // build verNum string
	      if (str.charAt(pos) == "." || 
	         (str.charAt(pos) <= "9" && str.charAt(pos) >= "0"))
	        verNum += str.charAt(pos);
	      else
	        break;
	    return verNum;
	    }
	  var verArray = navigator.appVersion.split(" ");
	  return verArray[0];
	  }

	function isVer4()  // is browser version 4.x?
	{
	  if (getBrowserVer() >= 4.0 && getBrowserVer() < 5.0)
	    return true;
	  else
	    return false;
	}
	
	function isGecko()
	{	
		var agt=navigator.userAgent.toLowerCase();
		return (agt.indexOf('gecko') != -1);
	}
	
	function isNav()
	{
		var agt=navigator.userAgent.toLowerCase();
		
	    // Note: Opera and WebTV spoof Navigator.  We do strict client detection.
	    // If you want to allow spoofing, take out the tests for opera and webtv.
	    var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
	                && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
	                && (agt.indexOf('webtv')==-1) && (agt.indexOf('hotjava')==-1));
				
		return is_nav ;					
	}    

	function isMajor()
	{
		return parseInt(navigator.appVersion);
	}
    function isMinor()
	{
		return parseFloat(navigator.appVersion);
	}
	function isNav6Up()
	{
		return (isNav() && (isMajor() >= 5));
	}

	function isNav6()
	{
		return (isNav() && (isMajor() == 5));
	}
