scroll with css

scroll with css

appudappuappudappu Posts: 5Questions: 2Answers: 0

how to add scroll-x with css.

add css as

table.display tbody{
max-width: 200px;
overflow-x: scroll;
overflow-y: auto;
}

my test case

https://live.datatables.net/xulecoko/1/edit

but scroll not appear to the table body.

how to add it to the table body with css only.

possible ?

Answers

  • allanallan Posts: 61,972Questions: 1Answers: 10,160 Site admin

    Nope. If it was possible, we'd have taken that approach in DataTables core. It is something I look into on a regular basis, but there just isn't the browser support for vertical scrolling the tbody, which is exceptionally frustrating. The hardest and most time consuming part of the DataTables code is the scrolling code!

    Horizontal scrolling can be faked by putting the table into a div and making that overflow-x: auto, but vertical scrolling, no - not until the browsers support it.

    Allan

  • appudappuappudappu Posts: 5Questions: 2Answers: 0

    Okay Allan.

    Cheers.

Sign In or Register to comment.