function popupWin(cardName, winW, winH, winTitle) {
  nn4 = (document.layers) ? true : false;
  ie4 = (document.all) ? true : false;
  nn6 = (document.getElementById && !ie4) ? true : false;   
  if(nn4 || ie4 || nn6) {
    posX = Math.round((screen.width - winW) / 2);
    posY = Math.round((screen.height - winH) / 2);
    posCode = (nn4 || nn6)? 'screenX='+posX+',screenY='+posY : 'left='+posX+',top='+posY;
  } else {
    posCode = '';
  }
  cardWindow = window.open('','_blank','menubar=no,toolbar=no,scrollbars=no,status=no,width='+winW+',height='+winH+','+posCode);
  cardWindow.document.open();
  cardWindow.document.write('<html><head><title>'+winTitle+'<\/title><\/head>');
  cardWindow.document.write('<body marginwidth=0 marginheight=0 topmargin=0 leftmargin=0 rightmargin=0 bottommargin=0>');
  cardWindow.document.write('<img src="'+cardName+'" width="'+winW+'" height="'+winH+'" /><\/body><\/html>');

  cardWindow.document.close();
  cardWindow.focus();
}