My question arose when I created my (first ever!) two columns.
I have a wrapper for my left and right columns, but the wrapper's height didn't expand to fit the left and right columns with each floated to its side respectively.
I found a solution online where it adds the style (is this the right word?) 'overflow: auto' to the wrapper. After some research, I've found several articles that explain what the overflow does, including this stackoverflow answer:Why "overflow: hidden" clears a float?
However, nothing in my research explains in a way I can understand why the wrapper's height doesn't auto-expand to fit the nested divs, the two columns.
Don't all things nested within a div are contained within that div? Doesn't this create boundaries for the inside elements?
Any help is appreciated for this noobie. Thanks!
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…