function checkOS() {
	/*alert(navigator.userAgent);*/
	var os="OT";
	var uAnt = navigator.userAgent; 
	if(uAnt.indexOf("Win") != -1) os = "WIN";
	if(uAnt.indexOf("Mac") != -1) {
		os = "OS9";
		for (i=0; i<navigator.plugins.length; i++) if (navigator.plugins[i].filename.indexOf(".") >= 0) os = "OSX";
	};
	if (uAnt.indexOf("X11") > -1) os = "UNIX"; 
	return os;
}
function checkBrowser() {
	/*alert(navigator.userAgent);*/
	var uAnt = navigator.userAgent; 
	if (uAnt.indexOf("Safari") > -1) return "SF"; 
	if (uAnt.indexOf("Opera") > -1) return "OP";
	if (uAnt.indexOf("Firefox") > -1) return "FF";
	if (uAnt.indexOf("MSIE") > -1) return "IE"; 
	if(document.layers) return "NN4";
	if(document.getElementById && !document.all) return "NN6";
	return "OT"; 
}




//css

//
if(checkOS() == "OSX"){
	if(checkBrowser() == "IE"){
	document.write("<link href='common/style_macosxie.css' rel='stylesheet' type='text/css'>");
	}else if(checkBrowser() == "SF"){
	//***FOR MAC Safari
	//standard
	document.write("<link href='common/style_mac.css' rel='stylesheet' type='text/css'>");
	}else{
	//***FOR MAC NETSCAPE
	//standard
	document.write("<link href='common/style_mac.css' rel='stylesheet' type='text/css'>");
	}
}else{
	if(checkBrowser() == "IE"){
	//***FOR WIN IE
	//standard
document.write("<link href='common/style.css' rel='stylesheet' type='text/css'>");
	}else{
	//***FOR WIN NETSCAPE
	//standard
document.write("<link href='common/style_ns.css' rel='stylesheet' type='text/css'>");
	}
}
//
//js_functions
function openpopwin(url,w,h){
x = ((screen.availWidth) / 2) - (w / 2);
y = ((screen.availHeight) / 2) - (h / 2);
wo=window.open(url,"about","width="+w+",height="+h+",left="+x+",top="+y+",toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,favorites=no,resizable=no");
wo.focus();
}