Bug with sScrollX

Bug with sScrollX

joshcomleyjoshcomley Posts: 4Questions: 0Answers: 0
edited October 2011 in Bug reports
Hi,

I can't find a search function for the forum, so apologies if this has already been mentioned.

I think there is a bug that reveals itself when using the "sScrollX" feature. The bug means that radio buttons in a table that were checked before using dataTabe() are no longer checked afterwards.

See this simple example:
http://jsfiddle.net/UC8gt/2/

Does anyone have any ideas for a workaround?

Cheers,
Josh

Replies

  • joshcomleyjoshcomley Posts: 4Questions: 0Answers: 0
    As a note, the bug does not appear to manifest itself when using checkboxes, only radio buttons:

    http://jsfiddle.net/UC8gt/3/
  • joshcomleyjoshcomley Posts: 4Questions: 0Answers: 0
    As another note, the bug appears to appear only in certain circumstances - for example, if I check the other radio button then all is OK:

    http://jsfiddle.net/UC8gt/4/
  • allanallan Posts: 63,107Questions: 1Answers: 10,394 Site admin
    > I can't find a search function for the forum

    There is a search bar at the top of every page on this site :-). It searches the whole site, not just the forum, but trust me, its much better than the built in forum searching options...

    Its a very odd issue indeed that you've found there. DataTables will not be cloning the contents of the cells in the configuration you've got there (which would be my first through - FixedColumns for example does that). Looking at the DOM in Inspector the 'checked' attribute is still there, so I suppose a horrible fix would be to use jQuery to get the checked radio boxes and then check them, but thats really nasty.

    I'll look into this a bit more over the next few days if I can.

    Allan
  • joshcomleyjoshcomley Posts: 4Questions: 0Answers: 0
    Thanks for the feedback - fair enough about the search; I tried using that search, but I've always found the Google Search things useless, not because it is useless, but because most sites don't configure it correctly and normally have a specific "Forum Search" facility. Not that "normally" is correct by any means! I should have given it a bit more time, sorry :)

    Yeh, for now we're going to wrap up calls to .dataTable with .dataTableHack and store and recheck the radio buttons. Will keep an eye out here for updates, thanks again for the quick response.
This discussion has been closed.