HTML CSS examples for CSS Property:background-color
Showing a Div with background-color only
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #wrapper {<!--from w w w . j a v a2s . c om--> margin: 25px 20px; height: auto; } #main_content { margin-left: 20px; margin-right: 20px; background: #fff;} #left_border, #right_border { display: block; background-color: #ff0000; } #left_border { float: left; } #right_border { float: right; } </style> </head> <body> <div id="wrapper"> <div id="left_border"> <div id="right_border"> <div id="main_content"> some text <br> some text <br> some text <br> some text <br> </div> </div> </div> </div> </body> </html>