Datatables columns not resizing properly

Datatables columns not resizing properly

Tylerlee12Tylerlee12 Posts: 8Questions: 5Answers: 0
edited June 2014 in Free community support

Hi guys,

So my datatables table doesn't resize properly when the screen gets smaller. Is there any way to make rows automatically shrink as the screen gets smaller rather than the page creating an x-axis and y-axis scrollbar? Here's a test case illustrating my problem.

http://live.datatables.net/ducuboj/2/edit

And the debug data for the actual table in question on my page webpage: http://debug.datatables.net/urucag

This question has an accepted answers - jump to answer

Answers

  • anaganag Posts: 48Questions: 2Answers: 7
    Answer ✓

    Your CSS is setting the tables container to a width fixed by pixels, not percentage.

    Take a look at the flexible table example http://datatables.net/examples/basic_init/flexible_width.html

    A table to be responsive is just a matter of how CSS styling is applied at different screen resolutions.

  • Tylerlee12Tylerlee12 Posts: 8Questions: 5Answers: 0
    edited June 2014

    I swore that I tried that prior to posting this question, but lo and behold this fixed my issue..thank you!

This discussion has been closed.