function embedFlash(sID, sURL, sWidth, sHeight)
{
document.write("<OBJECT classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH='" + sWidth + "' HEIGHT='" + sHeight + "' id='" + sID + "' ALIGN=''>");
document.write("<PARAM NAME=movie VALUE='" + sURL + "'>");
document.write("<PARAM NAME=quality VALUE=high>");
document.write("<PARAM NAME=bgcolor VALUE=#FFFFFF>");
document.write("<EMBED src='" + sURL + "' quality=high bgcolor=#FFFFFF  WIDTH='" + sWidth + "' HEIGHT='" + sHeight + "' NAME='" + sID + "' ALIGN='' TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED>");
document.write("</OBJECT>");
}

function getStrCenterCoord(dimY, dimX)
{
	var xx, yy;
	var s;

	xx = (window.screen.width - dimX) / 2;
	yy = (window.screen.height - dimY) / 2;
	s = "left="+xx+",top="+yy;

	return s;
}

function openPopup(sUrl, w, h, l, t, sRes, sScroll)
{
	var sTmp, newPop

	if (sRes == null) sRes = "no"
	if (sScroll == null) sScroll = "NO"
	
	if (w == null) w=420
	if (h == null) h=370
	//if (l == null) l=200
	//if (t == null) t=200
	
	sTmp = getStrCenterCoord(h,w);
	
	newPop = window.open(sUrl, "", "alwaysRaised,dependent,height=" + h + ",width=" + w + ",scrollbars=" + sScroll + ",resizable=" + sRes + "," + sTmp);
	
	if (newPop == null)
	{
		alert("OUCH! Non riuscendo ad aprire una nuova finestra,\nsarņ costretto a caricare la nuova pagina nella\nfinestra principale.\n\nPer visualizzare correttamente il sito puoi\ndisabilitare temporaneamente il blocco delle popup\n(posso assicurarti che qui non corri alcun rischio).\n\n                                                                  DITo'\n")
		document.location = sUrl
	}
	else
	{
		newPop.focus()
	}
}

function init()
{
	var y = (parseInt(window.document.body.clientHeight) - 488) / 2;
	mainDIV.style.top = y;
}