function Fensterweite () {
  if (window.innerWidth) {
    return window.innerWidth;
  } else if (document.body && document.body.offsetWidth) {
    return document.body.offsetWidth;
  } else {
    return 0;
  }
}

function Fensterhoehe () {
  if (window.innerHeight) {
    return window.innerHeight;
  } else if (document.body && document.body.clientHeight) {
    return document.documentElement.clientHeight ;
  } else {
    return 0;
  }
}

function neuAufbau (start) {
   if (getObjectRef('iframeContent')){
	  if (!OriginalHeight) OriginalHeight = getHeight('contentCell');
	  //if (!OriginalDiff) OriginalDiff = getHeight('warpper_main') - getHeight('page_content');
	  if (Hoehe != Fensterhoehe() || !Hoehe || start==1){
		Hoehe = Fensterhoehe();
		var newheight= Hoehe;
		var contentDiv = getObjectRef('iframeContent');
		
		var content_div_diff= getHeight('contentCell');		
		var newheight_page= content_div_diff;
		//alert(Fensterhoehe()+" "+OriginalDiff +" "+OriginalHeight+" "+newheight_page); 
       	//if (OriginalHeight <  newheight_page){
		   		   contentDiv.style.height= newheight_page-30 +"px";
	//	}else{
	//			   contentDiv.style.height= OriginalHeight +"px";
	//		}
   	}
   }
}

function getHeight(name) { 
	var el = getObjectRef(name); 
	return el.offsetHeight; 
} 

function getObjectRef(name) { 
	if(document.getElementById) return document.getElementById(name); 
	else if(document.all) return document.all[name]; 
	else return null; 
} 
