I'm trying to make all the div's
in the header column to be same hight so that content inside those divs match the height to the other divs in header.
I have added different colors to each div to better represent them, i'm looking to get the text or content inside the div to be in same line as other contents in other column of header.
table {
margin: 0 auto;
border: 1px solid;
}
table th {
border-top: 1px solid;
border-bottom: 1px solid;
border-right: 1px solid;
padding: 5px;
width: 40px;
}
table td {
border-bottom: 1px solid;
border-right: 1px solid;
padding: 5px;
}
.img {
background-color: lightgreen;
}
.img_1 {
height: 50px;
}
.img_2 {
height: 20px;
}
.img_3 {
height: 70px;
}
.title {
background-color: lightpink;
}
.description {
background-color: rgb(182, 255, 215);
}
.price {
background-color: rgb(249, 182, 255);
}
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" rel="stylesheet"/>
<table>
<thead>
<tr>
<th>
<div class="img img_1">Img</div>
<div class="title">Title</div>
<div class="description">Description</div>
<div class="price">Price</div>
</th>
<th>
<div class="img img_2">Img</div>
<div class="title">Title</div>
<div class="description">Description</div>
<div class="price">Price</div>
</th>
<th>
<div class="img img_3">Img</div>
<div class="title">Title</div>
<div class="description">Description Long Description</div>
<div class="price">Price</div>
</th>
</tr>
</thead>
<tbody>
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</tbody>
</table>
General giz of this the text inside the divs need to be same line as text in other divs in header.