html div nebeneinander code example
Example 1: div nebeneinander
.box {
float: left;
width: 32%;
margin-right: 2%;
padding: 20px;
background: #eee;
box-sizing: border-box;
}
Example 2: nebeneinander anordnen css
display: flex;
flex-direction: row;
Example 3: css 2 divs nebeneinander
#right{
background: green;
width: 100%;
}
#left {
margin-top: 5px;
background: red;
}
#container {
width: 800px;
}
<div id="container">
<div id="left"> This div is as big as it's content</div>
<div id="right"> rest of space</div>
</div>