function showWindow(url)
{
	intWidth = 780;
	intHeight = 900;
	intLeft = screen.width/2 - (intWidth/2);
	intTop = screen.height/2 - (intHeight/2);
  
  if (screen.width == 1024) 
  {
  	intLeft = screen.width/2 - (intWidth/2);
  	intTop = screen.height/2 - (intHeight/2);
  	intWidth=780;
  	intHeight=700;
  }
  
	toolbar_str = 'no';
	menubar_str = 'no';
	statusbar_str = 'no';
	scrollbar_str = 'yes';
	resizable_str = 'no';
	objWindow = window.open(url, 'popup', 'left='+intLeft+',top='+intTop+',width='+intWidth+',height='+intHeight+',toolbar='+toolbar_str+',menubar='+menubar_str+',status='+statusbar_str+',scrollbars='+scrollbar_str+',resizable='+resizable_str);
	if (objWindow)
	  objWindow.focus();
	else
	  alert ('Ihr Browser unterstützt keine Popups.');
}

function showImage(file,width,height)
{
  intWidth = width;
	intHeight = height;
	intLeft = screen.width/2 - (intWidth/2);
	intTop = screen.height/2 - (intHeight/2);
  
	toolbar_str = 'no';
	menubar_str = 'no';
	statusbar_str = 'no';
	scrollbar_str = 'no';
	resizable_str = 'no';
	url='image.htm?file='+file;
	objWindow = window.open(url, 'image', 'left='+intLeft+',top='+intTop+',width='+intWidth+',height='+intHeight+',toolbar='+toolbar_str+',menubar='+menubar_str+',status='+statusbar_str+',scrollbars='+scrollbar_str+',resizable='+resizable_str);
	if (objWindow)
	  objWindow.focus();
	else
	  alert ('Ihr Browser unterstützt keine Popups.');
}

function loadImage()
{
  var p =location.href.indexOf('?file=')+6;
  var f = location.href.substr(p);
  var i = document.getElementById('fimage');
  i.src = f;
}

function opacity(id, opacStart, opacEnd, millisec) 
{ 
  var speed = Math.round(millisec / 100); 
  var timer = 0; 

  if(opacStart > opacEnd) 
  { 
    for(i = opacStart; i >= opacEnd; i--) 
    { 
      setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed)); 
      timer++; 
    } 
  } else if(opacStart < opacEnd) 
  { 
    for(i = opacStart; i <= opacEnd; i++) 
    { 
      setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed)); 
      timer++; 
    } 
  } 
} 

function changeOpac(opacity, id) 
{ 
  var object = document.getElementById(id).style; 
  object.opacity = (opacity / 100); 
  object.MozOpacity = (opacity / 100); 
  object.KhtmlOpacity = (opacity / 100); 
  object.filter = "alpha(opacity=" + opacity + ")"; 
} 
