How to place three DIVs in regular spacing inline.
HTML
inside <div class="modal-body">
<div id="container">
<div id="left">A</div>
<div id="center">B</div>
<div id="right">C</div>
</div>
CSS
with width: 350px
try with width: 100%
#container {
width:350px;
text-align:center;
margin:0 auto;
}
#left {
float:left;
width:100px;
height: 100px;
background: #888;
}
#center {
display: inline-block;
margin:0 auto;
width:100px;
height: 100px;
background: #888;
}
#right {
float:right;
width:100px;
height: 100px;
background: #888;
}
Example
Written by Karol Gontarski
Related protips
1 Response
You are asking the question or showcasing your findings? I wonder if this would work. You placed any demo?
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Css
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#