How to you define a row in div tags
High level example in pseudo code:
[DIV TAGS LEFT] [DIV TAGS CENTER] [DIV TAGS RIGHT]
[WHAT GOES HERE?????]
[DIV TAGS LEFT] [DIV TAGS CENTER] [DIV TAGS RIGHT]
[WHAT GOES HERE?????]
[DIV TAGS LEFT] [DIV TAGS CENTER] [DIV TAGS RIGHT]
To create rows, add a div with a class=“row” that encases the column code. Rows must always be placed inside of a container. Rows span the width of the container. They have a negative 15 pixel margin at the end, essentially removing the 15 pixel margin set by its container.
By default, if we have multiple div tags it will be displayed one below the other. In othere words, each div will be displayed in a separate line. To display multiple div tags in the same line, we can use the float property in CSS styles. The float property takes left, right,none(default value) and inherit as values.
this may work
<style>
.parent {
margin-bottom: 15px;
padding: 10px;
color: #0A416B;
clear:both;
}
.left, .center, .right{
float:left;
width:32%;
border:1px solid #CEDCEA;
padding:5px;
}
</style>
<div class="parent">
<div class="left">
Left
</div>
<div class="center">
center
</div>
<div class="right">
right
</div>
<div style="clear:both;"></div>
</div>
If I understand the question, you need this HTML structure:
<div class="row">
<div class="left"></div><div class="center"></div><div class="right"></div>
</div>
... and this CSS:
div.row {
clear:both;
}
<div class="parent">
<div class="left">left</div>
<div class="center">center</div>
<div class="right">right</div>
</div>
styling:
.parent {
overflow: auto;
}
.parent>div {
float: left;
width: 33%;
}
This should give you what your looking for.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With