Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to make a div inside a td to stretch?

Tags:

html

css

I have a table like:

<table>
<tr>
<td>...</td>
<td><div class="stretch"></div></td>
</tr>
</table>

I need to get the .stretch to fit the height of the td. Currently the div has a height of 0. What am I missing?

like image 688
Tower Avatar asked Nov 04 '10 06:11

Tower


1 Answers

the td must have a set size then you set the div's height:100%; or inherit pretty the same thing and you'll be good to go

like image 180
Breezer Avatar answered Sep 21 '22 12:09

Breezer