function printContent(){
var objTitel = document.getElementById("lblTitel");
var objTitelPrint = parent.printFrame.document.getElementById("divTitel");
objTitelPrint.innerHTML=objTitel.innerHTML;
var objContent = document.getElementById("lblContent");
var objContentPrint = parent.printFrame.document.getElementById("divContent");
objContentPrint.innerHTML=objContent.innerHTML;
parent.printFrame.focus();
parent.printFrame.print();
}

function go2URL(address)
{
  var elFrame = document.getElementById('doiFrame');
  elFrame.src = address;
}
function newWindow(address)
{
	var maxW = screen.width;
	var maxH = screen.height;
	var w = 800;
	var h = 600;
	var _top = Math.floor((maxH - h) / 2);
	var _left = Math.floor((maxW - w) / 2);
	
	var win = window.open(address,'doiW',"toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,copyhistory=yes,width="+w+",height="+h);
	win.moveTo(_left,_top);
	win.focus();
}
					function swapImage(obj){
				var imgSrc = obj.src;
				
				imgSrc = imgSrc.substr(0,imgSrc.length-4);
				obj.src = imgSrc + '_o.gif';
			}
			function restoreImage(obj){
				var imgSrc = obj.src;
				
				imgSrc = imgSrc.substr(0,imgSrc.length-6);
				obj.src = imgSrc + '.gif';
			}	
function deep1(no,deep)
{
  if(deep == 10)
    return;
  for(var i=0;i<5;i++)
  {
	switch(no)
	{
      case 2:
        eval("pmL"+no+""+deep+""+i+"=new TPopMenu('Menu "+i+"','0','','',' Menu "+deep+" "+i+"');"); 
	    break;
 	  default:
		eval("pmL"+no+""+deep+""+i+"=new TPopMenu('Menu "+i+"','','','',' Menu "+deep+" "+i+"');"); 
	}
       
  }
  deep1(no,++deep);
}
function deep2(par,no,deep)
{ 
  if(deep == 10)
    return;
  var j = Math.round(Math.random()*4);
  for(var i=0;i<5;i++)
  {
    eval(par+".Add(pmL"+no+""+deep+""+i+");");
    if(i== j)
    {  
      var d = deep+1;  
      deep2("pmL"+no+""+deep+""+i,no,d);
    }
  }
}
function popup(url){
	var myWin;
	myWin = window.open(url,'pop','location=no,width=400,height=500');
	myWin.focus();

}
function popImage(url,mywidth,myheight){
	var myWin;
	myWin = window.open(url,'popImage','location=no,width='+mywidth+',height='+myheight);
	myWin.focus();

}
function popform(url){
	var myWin;
	myWin = window.open(url,'popform','location=no,left=20,top=20,width=500,height=430,scrollbars=yes, resizable=yes');
	myWin.focus();

}

function popformbreed(url){
	var myWin;
	myWin = window.open(url,'popform','location=no,left=20,top=20,width=700,height=480,scrollbars=yes, resizable=yes');
	myWin.focus();

}
function toonVergroting(url){
	var myWin;
	myWin = window.open("","popImage","location=no,width=400,height=400");
		
	myWin.document.open();
	
		myWin.document.write("<HTML><HEAD>");
			
		myWin.document.write("<TITLE>Vergroting</TITLE>");
		myWin.document.write('<script language="javascript">\n');
		myWin.document.write('function resizeWindow(){\n');
		myWin.document.write('if(  navigator.appName=="Netscape" && parseInt(navigator.appVersion)==5){\n');
		myWin.document.write('height = window.innerHeight;\n');
		myWin.document.write('width = window.innerWidth;}\n');
		myWin.document.write('else{\n');
		myWin.document.write('if (document.all){\n');
		myWin.document.write('height = document.body.scrollHeight;\n');
		myWin.document.write('width = document.body.scrollWidth;}\n');
		myWin.document.write('else if (document.layers){\n');
		myWin.document.write('height = window.innerHeight;\n');
		myWin.document.write('width = window.innerWidth;}}\n');
		myWin.document.write('window.resizeTo(width + 10, height + 20);\n');
		myWin.document.write('self.focus();}\n');
		
		myWin.document.write('</script>\n');
		myWin.document.write("</HEAD>");
		myWin.document.write("<BODY leftmargin='0' topmargin='0' onload='resizeWindow()' >");
		myWin.document.write("<img src='" + url + "'>");
		myWin.document.write("</BODY>");
		myWin.document.write("</HTML>");
		
	myWin.document.close();
}
function resizeWindow(){
				if(  navigator.appName=='Netscape' && parseInt(navigator.appVersion)==5){
					height = window.innerHeight;
					width = window.innerWidth;
				}
				else{
					if (document.all){
							height = document.body.scrollHeight;
							width = document.body.scrollWidth;
							}
					else if (document.layers){
							height = window.innerHeight;
							width = window.innerWidth;
					}
				}
	window.resizeTo(width + 10, height + 20)
	self.focus();
}