function columnheight(divA, divB, divSet){
  rhand = document.getElementById(divA).offsetHeight;
  lhand = document.getElementById(divB).offsetHeight;
  cntr = document.getElementById(divSet).offsetHeight;
  var newheight = Math.max(lhand, rhand) - 30; 
  //newheight = Math.max(newheight, cntr); 
  document.getElementById(divSet).style.height = newheight + "px";
}

window.onload=function(){
  columnheight("left","centerwrap","right");
}

function toggleDiv(divid){
  if(document.getElementById(divid).style.display == 'none'){
    document.getElementById(divid).style.display = 'block';
  }else{
    document.getElementById(divid).style.display = 'none';
  }
  columnheight('left', 'centerwrap', 'right');
}
