CSS clearfix not working
问题 This (http://jsfiddle.net/77RRA/1/) is working, while this (http://jsfiddle.net/77RRA/) is not. Isn't clearfix supposed to substitute the line <div style="clear: both;"></div> ? 回答1: Isn't clearfix supposed to substitute the line <div style="clear: both;"></div> Yes. The clearfix is there to avoid a non-semantic empty tag. However, for this to work you need to place it on the parent element. (Example) In your case however, it does not address the problem that siblings will ignore the floated