/* function to toggle image */
function toggleImage2(imgObjekt,status){
	imagepath = "img/";
	name = imgObjekt.name;
	if (status==1){
		imageName = imagepath + name + "_a.gif";
	}else{
		imageName = imagepath + name + ".gif";
	}
	theImage = new Image(); 
	theImage.src = imageName;
	document.images[name].src = theImage.src;
}
/* function to toggle image */
// can also be used for currently highlighted items
function toggleImage(imgObjekt,status){
	imagepath = "img/";
	name = imgObjekt.name;
	if (status==1){
		// generate the new image-path-name
		imageName = imagepath + name + "_a.gif";
		//store the current image in an property
		imgObjekt.currentSrc = imgObjekt.src;
	}else{
		imageName = imagepath + name + ".gif";
		// if there is stored an image in the property use that one istead of the now generted (in this case if the image is already highlighted it stays highlighted)
		if (imgObjekt.currentSrc){
			imageName = imgObjekt.currentSrc;
		}
	}
	theImage = new Image(); 
	theImage.src = imageName;
	document.images[name].src = theImage.src;
}
/************************************************************************************************  
  Druckfenster oeffnen:
************************************************************************************************/

function openWinDruck(url){
  var MyWindow =0;
  var x =0;
  var breite =750;
  var hoehe =500;
  MyWindow = window.open(url,'druck','toolbar=1,location=0,directories=0,statusbar=0,menubar=1,scrollbars=yes,resizable=yes,width='+breite+',height='+hoehe);
  if (MyWindow){
    MyWindow.moveTo(screen.width/2-(breite/2+x),10);
    MyWindow.focus();
  }
}
/************************************************************************************************/