How to make the height of rows fixed?

How to make the height of rows fixed?

yusrilyusril Posts: 14Questions: 10Answers: 0

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

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 61,773Questions: 1Answers: 10,112 Site admin
    Answer ✓

    HTML tables typically just wrap to the contents - so if you have a large image, you will end up with a large cell.

    Perhaps the correct thing to do here is to limit the height of the image:

    table.dataTable tbody td img {
      max-height: 40px;
    }
    

    Allan

This discussion has been closed.