I have a parent div, I set max heigth, overflow auto for it. And it have two children div. But I saw the height of parent div equals sum of two children's height. And It only working when I add padding bottom to Parent div or Last children div. Thanks for any help.
If the children have in sum bigger height, you should increase the size of the parent.
I recommend you to learn about flex-box, here's a good website for that flex-box
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.