HTML CSS examples for CSS Widget:Div Table
Switching from tables to divs with CSS
<html> <head> <title>Lo</title> </head> <!--from w w w . j a v a2 s . com--> <body> <p>Lorem ipsum dol</p> <div style="height: 200px; background-color: red;"> <div style="height: 100%; margin-right: 20%;"> <div style="float: left; width: 30px; height: 100%; background-color: green;"> Lor </div> <div style="float: left; width: 80%; height: 100%; background-color: yellow;"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi ullamcorper molestie lacus sed fermentum. Aliquam erat volutpat. Vestibulum tortor neque, ornare vitae tempor hendrerit, luctus at neque. Phasellus sed quam pharetra, tincidunt tortor in, pharetra nisl. Maecenas aliquam luctus mauris, vitae venenatis diam imperdiet vel. Donec tortor diam, pretium vitae nibh vitae, consectetur lacinia sem. Proin luctus facilisis volutpat. Ut semper sit amet purus quis o </div> <div style="float: left; width: 30px; height: 100%; background-color: blue;"> Lor </div> <div style="clear: both;"></div> </div> </div> <p>Lorem ipsum dolor</p> </body> </html>