html - how do i place three div side by side in header -
html code
<div class="header" style="float:left"> <div class="logo"> <img src="some image" height="200px" width="200px"/> </div> <div class="name">company name</div> <div class="pic"> <img src="some image" height="200" width="200"/> </div> </div>
css styling
header{background-color:red;width:1200px;height:400px;float:;} .logo{width:17%;} .name{color:#adff2f;font-size:48pt;margin-left:250px;width:38%} .pic{;margin-left:950px;}
.header > div { float: left; }
also, header
class in css needs have .
in front of it.
you need remove margin-left .pic
Comments
Post a Comment