javascript - how to show the bottom of div with scroll? -
this question has answer here:
- scroll bottom of div? 16 answers
i have div scroll have information mysql.
this div supose chat (like facebook chat) , refresh ajax every seconds.
i need div alwase show me information in bottom (like facebook chat)
how made (keep scroll down)?
<div style='width:100%; height:275px; bottom:25px; overflow-y:scroll;' id='aaa'> chat </div>
try following
var objdiv = document.getelementbyid("your_div"); objdiv.scrolltop = objdiv.scrollheight;
Comments
Post a Comment