function isFlashInstalled() {
  var MM_contentVersion = 5;
  var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
  if ( plugin ) {
    var words = navigator.plugins["Shockwave Flash"].description.split(" ");
    for (var i = 0; i < words.length; ++i) {
      if (isNaN(parseInt(words[i])))
      continue;
      var MM_PluginVersion = words[i]; 
    }
    var flashInstalled = MM_PluginVersion >= MM_contentVersion;
  }
  else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.appVersion.indexOf("Win") != -1)) {
    document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n');
    document.write('on error resume next \n');
    document.write('flashInstalled = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & MM_contentVersion)))\n');
    document.write('</SCR' + 'IPT\> \n');
    return flashInstalled;
  }
}

function popUpImg(img,name) {
	
   var myImg = new Image();
   myImg.src = img;
   var posImageName = img.lastIndexOf("/") + 1;
   var imagePathLength = img.length;
   var imgName = img.substring(posImageName,imagePathLength - 4);
   
   var imgHeight = 600;
   var windowWidth = 400;
   var windowHeight = 600 ;
   var xpos=(screen.width-windowWidth)/2; 
   var ypos=(screen.height-windowHeight)/2;
   var eigenschaften="top=" + ypos + ",left=" + xpos + ",width=" + windowWidth + ",height=" + windowHeight ;
   //var eigenschaften="screenX=100,screenY=100,width=" + windowWidth + ",height=" + windowHeight;
// weitere Attribute hinzufügen
	eigenschaften= eigenschaften + ",menubar=no,resizable=yes,scrollbars=no";

   var imgWin=window.open('','Bild',eigenschaften);
   
   with (imgWin.document) {
      open();
      write('<HTML>');
      write(' <HEAD>');
      write(' <title>'+ name +'</title>');
      write(' <script type="text/JavaScript" language="JavaScript"> ');
      write(' function resize() { ');
      write(' var width = document.getElementById("img").width; ');
      write(' var height = document.getElementById("img").height; ');
      write(' window.resizeTo(width + 8, height + 25 ); ');
      write(' window.innerWidth = width; ');
      write(' window.innerHeight = height; ');
      write(' self.focus(); ');
      write(' var xpos=(screen.width-width)/2; ');
      write(' var ypos=(screen.height-height)/2; ');
      write(' window.moveTo(xpos, ypos); ');
      write(' } ');
      write(' </script> ');
      
      
      write(' </HEAD>');
      write(' <BODY style="margin: 0px;" onLoad="resize();">');
      write(' <center><a href="" onClick="JavaScript:self.close()">')
      write(' <img id="img" src="'+img+'" alt="'+ imgName +'"  title="'+ name +'" border="0"></a>');
      write(' </center></BODY>');
      write('</HTML>');
      close();
   }
   
}

