Home > Article > Web Front-end > JavaScript fixes the DIV height and automatically adds scroll bars to the exceeded part
function setheight() { var div=document.getElementById("event_basicInfo"); //div.style.width="40%"; div.style.height=400; div.style.overflow="auto"; } window.onload=setheight;