Reputation: 1932
I have a table with a column that contains random size of image. Because of this image column, it changes the height of each row.
Therefore, Is there any option to fix the height of all rows?
Here is the demo: http://live.datatables.net/wisalaru/1/edit
If there is no such an option like so, is there any other solution for that?
Upvotes: 0
Views: 45
Reputation: 1
The easiest way is perhaps to fix the height of the image itself. The images will scale down (or up, if they're smaller).
If, for example, you set tbody img { height: 40px; }
then a tr
will only exceed 40px
when other content in the same row causes it to be.
Upvotes: 0
Reputation: 391
Just give a fixed height in the style attribute as well as proper overflow values. Then add the img-responsive class of bootstrap to the image
Upvotes: 1