
  var minheight = 539;
  //var heightdiff = 160 +35;
  var topbottomheight = 130+40;
  
  function init_resize (){
    my_resize("proglist");
    my_resize("content-scrollable");
    my_resize("progindexlist");
	
  }
  
  function my_resize (id){

  targetcontainer = document.getElementById(id);
  otherstuffheight = 0;
	
	if (targetcontainer != null){
		if (id == 'proglist') {
			otherstuffheight = document.getElementById('catlist').offsetHeight;
		}

		if (id == 'progindexlist') {
			//otherstuffheight = document.getElementById('listcontrolls').offsetHeight;
		}

		
		heightdiff = topbottomheight + otherstuffheight;
		
	    //alert (window.innerHeight);
	    var view_height;
	    view_height = 0;
	    if (window.innerHeight) view_height = window.innerHeight
	    else if (document.body.clientHeight) view_height = document.body.clientHeight;

	    if (view_height < minheight) view_height = minheight;

	    targetcontainer.style.height = view_height - heightdiff;
	}

    //alert( view_height - heightdiff ) ;
    //alert( targetcontainer.style.overflow) ;
  }

	
  window.onresize = init_resize;
