Conflict between dynamic column toggling and individual column filtering examples

Conflict between dynamic column toggling and individual column filtering examples

DMRDMR Posts: 2Questions: 0Answers: 0
edited January 2014 in General
As per this discussion - http://datatables.net/forums/discussion/comment/49828 (since closed), there is a conflict if you try to use the dynamic column toggling and column filtering examples together.

Here's the naive code as per the example:

http://live.datatables.net/utuN/1/edit?html,js,output

Here's a version attempting to use fnVisibleToColumnIndex, as per the suggestion in the original discussion

http://live.datatables.net/utuN/2/edit?html,js,output

I haven't made this work - can anyone point out where I've gone wrong?

Many thanks,
Dave

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Are you willing to give DataTables 1.10 a spin? The new API makes this kind of thing much easier. Here is an example of the column filtering: https://github.com/DataTables/DataTables/blob/master/examples/api/multi_filter.html

    And combined with the column visibility example: http://live.datatables.net/UJuR/1/edit .

    Less code, easier, clearer, better :-). 1.10 is going to be going into beta very soon.

    Allan
  • DMRDMR Posts: 2Questions: 0Answers: 0
    Allan,

    That works well and the code is much nicer. I'm now using 1.10 :-)

    Thanks.
    Dave
This discussion has been closed.