function centra(win,w,h)
{
 var W = win.screen.width;
 var H = win.screen.height;
 var x = (W/2)-(w/2);
 var y = (H/2)-(h/2);
 return 'left='+x+',top='+y+',';
}

function CentraMacPc(url,winname,WidthPopUp,HeightPopUp,openproperties){

	var ret = '';

		if (navigator.platform.indexOf("Mac")>-1 && (navigator.appName.indexOf("Internet"))>-1){ 
		ret = centra(this.window,(WidthPopUp-16),(HeightPopUp-16));
		if (openproperties.length!=0) {
			ret = openproperties + "," + ret; 
		}
		win=window.open(url,winname,ret+'width='+WidthPopUp-16+',height='+HeightPopUp-16); 
	} else { 
	alert
		ret = centra(this.window,WidthPopUp,HeightPopUp);
		if (openproperties.length!=0) {
			ret = openproperties + "," + ret; 
		}
		win=window.open(url,winname,ret+'width='+WidthPopUp+',height='+HeightPopUp); 
	}
}


function MM_popupMsg(msg) { //v1.0
  alert(msg);
}
