function BrowserCheck(){
		var b = navigator.appName;
										//■以下全てWindowsでの検証結果
		if (b == "Netscape") this.b = "NN";				//NN4.71・NN7.1・Mozilla7.20等
		else if (b == "Microsoft Internet Explorer") this.b = "IE";	//IE6、Opera7.20等
		else this.b = b;						//上記２行以外

		this.version = navigator.appVersion;				//IE6		= 4.0 (compatible; MSIE 6.0; Windows NT 5.1; istb 702)
										//Opera7.20 	= 4.0 (compatible; MSIE 6.0; Windows NT 5.1)
										//Mozilla7.20	= 5.0 (Windows; en-US)
										//NN7.1		= 5.0 (Windows; ja-JP)
										//NN4.71	= 4.79 [en] (Windows NT 5.0; U)

		this.vSub = navigator.vendorSub;				//IE6		= undefined
										//OPERA7.20	= undefined
										//Mozilla7.20	= 0.6.1
										//NN7.1		= 7.1
										//NN4.71	= undefined


		this.userAgent = navigator.userAgent;				//IE6		= Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; istb 702)
										//OPERA7.20	= Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.20 [ja]
										//Mozilla7.20	= Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5a) Gecko/20030728 Mozilla Firebird/0.6.1
										//NN7.1		= Mozilla/5.0 (Windows; U; Windows NT 5.1; ja-JP; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)
										//NN4.71	= Mozilla/4.79 [en] (Windows NT 5.0; U)

		this.appVersion = navigator.appVersion;				//this.versionと同じでは？

		this.v = parseInt(this.version);				//IE6		= 4
										//OPERA7.20	= 4
										//Mozilla7.20	= 5
										//NN7.1		= 5
										//NN4.71	= 4

		this.vs = parseFloat(this.vSub);				//IE6		= NaN
										//OPERA7.20	= NaN
										//Mozilla7.20	= 0.6
										//NN7.1		= 7.1
										//NN4.71	= NaN
		
		this.NN = (this.b == "NN");					//Mozilla7.20・NN7.1・NN4.71
		this.NN3 = (this.b == "NN" && this.v == 3);			//
		this.NN4 = (this.b == "NN" && this.v == 4);			//NN4.71
		this.NN6x = (this.b == "NN" && this.v == 5 && this.vs >= 6.01);	//NN7.1(NN6.01以上、Mozilla含まず？)
		this.NN6 = (this.b == "NN" && this.v == 5);			//Mozilla7.20、NN7.1（NN6.0以上）
		this.NN7 = (this.b == "NN" && this.v == 5 && this.vs >= 7);	//NN7.1(NN7以上？Mozilla含まず？)
		this.NN4Over = (this.b == "NN" && this.v >= 4);			//navigator.appNameが"Netscape"でnavigator.appVersionが4以上（Mozilla7.20・NN7.1・NN4.71）
		
		this.IE = (this.b == "IE");
										//●以下IEのappversionは正しくないのでuseAgentで調べる
		this.IE3 = (this.userAgent.indexOf('MSIE 3')>0);
		this.IE45 = (this.userAgent.indexOf('MSIE 4.5')>0);
		this.IE401 = (this.userAgent.indexOf('MSIE 4.01')>0);
		this.IE4 = (this.userAgent.indexOf('MSIE 4')>0);
		this.IE51 = (this.userAgent.indexOf('MSIE 5.1')>0);
		this.IE512 = (this.userAgent.indexOf('MSIE 5.12')>0);
		this.IE514 = (this.userAgent.indexOf('MSIE 5.14')>0);
		this.IE52 = (this.userAgent.indexOf('MSIE 5.2')>0);
		this.IE5 = (this.userAgent.indexOf('MSIE 5')>0);
		this.IE6 = (this.userAgent.indexOf('MSIE 6')>0);		//IE6.0
		
		this.GEK = (this.userAgent.indexOf("Gecko") != -1);		//Mozilla7.20・NN7.1
		this.SAF = (this.userAgent.indexOf("Safari",0) != -1);		//Mac用ブラウザSafari
		this.CAB = (this.userAgent.indexOf("iCab",0) != -1);		//Mac用ブラウザiCab
		this.OPE = (this.userAgent.indexOf("Opera",0) != -1);		//Opera7.20
		
		this.Win = (this.userAgent.indexOf('Win',0) != -1);		//Win版のIE6・OPERA7.20・Mozilla7.20・NN7.1・NN4.71正しく判別できる
		this.Mac = (this.userAgent.indexOf('Mac',0) != -1);
		this.MacOSX = (this.userAgent.indexOf('Mac OS X',0) != -1);

										//●MacOSX版IEのuseAgentにMacOSXの文字は含まれないので以下で個別に調べる
		if(this.IE512 || this.IE52){
			this.MacOSX=true;
		}
		else if(this.IE514){
			if (navigator.plugins) {
				for (i=0; i < navigator.plugins.length; i++ ) {
					if (navigator.plugins[i].name.indexOf('QuickTime') >= 0 && navigator.plugins[i].filename.indexOf('.plugin')!=-1){ //navigator.plugins.nameに'QuickTime'がつくものがありnavigator.plugins[i].filenameに'.plugin'がある？マジ？
						this.MacOSX=true;
					}
				}
			}
		}

		this.Unix = (this.appVersion.indexOf('X11',0) != -1);
}

var checkB = new BrowserCheck();