Home  >  Article  >  Web Front-end  >  js fixed DIV height, a simple way to automatically add scroll bars beyond the part_javascript skills

js fixed DIV height, a simple way to automatically add scroll bars beyond the part_javascript skills

WBOY
WBOYOriginal
2016-05-16 17:29:241085browse
Copy code The code is as follows:

function setheight()
{
var div=document .getElementById("event_basicInfo");
//div.style.width="40%";
div.style.height=400;
div.style.overflow="auto";
}
window.onload=setheight;
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn