HTML CSS examples for CSS Layout:Float
Set background on div and float its children
<html> <head></head> <body> <div style="background: #CCC; width:100%; height:50px;position:relative;"> <div style="float:right;"> right </div> <!--from w ww . ja v a 2 s . com--> <div style="float:left;"> left </div> </div> </body> </html>