HTML CSS examples for CSS Layout:Box
Aligning 3 block equally spaced box
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .box {<!-- ww w . j a v a 2 s . c om--> color:Chartreuse; font-family:Helvetica, Arial, sans-serif; font-size:13px; background-color:yellow; height:71px; width:191px; padding:6px; margin-top:11px; margin-left:11px; float:left; } p { margin-left:60px; padding-top:3px; } a { margin-left:0px; margin-top:11px; position:absolute; } </style> </head> <body> <div id="box1" class="box"> <img src="https://www.java2s.com/style/demo/Firefox.png" style="float: left;"> <p> <b>Lorem</b>Lorem ipsum dolor sit amet, consectetur adipiscing </p> <a href="#">Lorem ipsum dolor </a> </div> <div id="box2" class="box"> <img src="https://www.java2s.com/style/demo/Firefox.png" style="float: left;"> <p> <b>Lorem</b>Lorem ipsum dolor sit amet, consectetur adipiscing </p> <a href="#">Lorem ipsum dolor </a> </div> <div id="box2" class="box"> <img src="https://www.java2s.com/style/demo/Firefox.png" style="float: left;"> <p> <b>Lorem ip</b>Lorem ipsum dolor sit amet, consectetur adipiscing </p> <a href="#">Lorem ipsum dolor </a> </div> </body> </html>