thread automatic recreation problem

thread automatic recreation problem

frede_schfrede_sch Posts: 3Questions: 0Answers: 0
edited February 2012 in General
Hi all,

I'm setting in my datatable "sScrollY": "200px" and other things. After the datatable being initilized I have a script that change the content of the first 6 of 20 columns of the header to drop downs. The problem is that when I'm using "sScrollY", the datatable recreates the thread element and do not recreate my changes correctly. Is there a way to disable this feature of recreation of the thread or something to solve my problem?

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    The issue you are encountered is fundamentally before of how DataTables works with scrolling tables. It will create a 'fixed' header table and move the original THEAD into that. Then the body table is put into a scrolling div, thus giving the scrolling interface. So you don't want to manipulate the THEAD in the original table because that is just a clone of the real header and is disposable.

    What you want to do is work with the THEAD in the "div.dataTables_scrollHeadInner table thead" element.

    Have a poke around a scrolling table with Firebug / Inspector and you'll see the markup used.

    Allan
  • frede_schfrede_sch Posts: 3Questions: 0Answers: 0
    Hey Allan, thanks, I've solved my problem here. Thank you!
This discussion has been closed.