function newWindow(a_str_windowURL, a_str_windowName, a_int_windowWidth, a_int_windowHeight, a_bool_scrollbars, a_bool_resizable, a_bool_menubar, a_bool_toolbar, a_bool_addressbar, a_bool_statusbar, a_bool_fullscreen) {
  var int_windowLeft = (screen.width - a_int_windowWidth) / 2;
  var int_windowTop = (screen.height - a_int_windowHeight) / 2;
  var str_windowProperties = 'height=' + a_int_windowHeight + ',width=' + a_int_windowWidth + ',top=-100,left=-100,scrollbars=' + a_bool_scrollbars + ',resizable=' + a_bool_resizable + ',menubar=' + a_bool_menubar + ',toolbar=' + a_bool_toolbar + ',location=' + a_bool_addressbar + ',statusbar=' + a_bool_statusbar + ',fullscreen=' + a_bool_fullscreen + '';
  var obj_window = window.open(a_str_windowURL, a_str_windowName, str_windowProperties)
    if (parseInt(navigator.appVersion) >= 4) {
      obj_window.window.focus();
    }
}

function aprimodulo(par, par2,w,h,didascalia)
{
  var popupWin = window.open('', '',par2);
  // popupWin.document.write('<html><body><img src='+par+' ></body></html>');
  popupWin.document.write('<html><body><center><img src=' + par + ' width=' + w + ' height=' + h + '></center></body></html>');
}

function stampa(str) 
{
  searchWin = window.open(str,'stampa','scrollbars=yes,resizable=no,width=760,height=420,status=no,location=no,toolbar=no');
  //        searchWin.refer = self;
}

function amico(str) 
{
  searchWin = window.open(str,'amico',   'scrollbars=yes,resizable=no,width=240,height=230,status=no,location=no,toolbar=no');
  //        searchWin.refer = self;
}

function stampa_flash(percorso, width, height, id)
{
  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\" id=\""+id+"\" width=\""+width+"\" height=\""+height+"\">");
  document.write("<param name=\"movie\" value=\""+percorso+"\">");
  document.write("<param name=\"menu\" value=\"false\">");
  document.write("<param name=\"quality\" value=\"high\">");
  document.write("<param name=\"scale\">");
  document.write("<param name=\"bgcolor\" value=\"#ffffff\">");
  document.write("<embed src=\""+percorso+"\" menu=\"false\" quality=\"high\" scale=\"noborder\" bgcolor=\"#ffffff\" width="+width+" height="+height+" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\">");
  document.write("</embed>");
  document.write("</object>");
}

function PopupCentrata() 
{
  var w = 800;
  var h = 600;
  var l = Math.floor((screen.width-w)/2);
  var t = Math.floor((screen.height-h)/2);
  window.open("popup.php","","width=" + w + ",height=" + h + ",top=" + t + ",left=" + l);
}

function newWindow(a_str_windowURL, a_str_windowName, a_int_windowWidth, a_int_windowHeight, a_bool_scrollbars, a_bool_resizable, a_bool_menubar, a_bool_toolbar, a_bool_addressbar, a_bool_statusbar, a_bool_fullscreen) {
  var int_windowLeft = (screen.width - a_int_windowWidth) / 2;
  var int_windowTop = (screen.height - a_int_windowHeight) / 2;
  var str_windowProperties = 'height=' + a_int_windowHeight + ',width=' + a_int_windowWidth + ',top=' + int_windowTop + ',left=' + int_windowLeft + ',scrollbars=' + a_bool_scrollbars + ',resizable=' + a_bool_resizable + ',menubar=' + a_bool_menubar + ',toolbar=' + a_bool_toolbar + ',location=' + a_bool_addressbar + ',statusbar=' + a_bool_statusbar + ',fullscreen=' + a_bool_fullscreen + '';
  var obj_window = window.open(a_str_windowURL, a_str_windowName, str_windowProperties)
    if (parseInt(navigator.appVersion) >= 4) {
      obj_window.window.focus();
    }
}

