Datatables Checkbox Bug in Firefox
Datatables Checkbox Bug in Firefox
rfitzwater
Posts: 57Questions: 5Answers: 1
I am having trouble tracking down a bug that occurs in Firefox, but not Safari. I have a data table with two columns, one of those columns are checkboxes. When a user selects some of the checkboxes, then submits the form, everything works properly. The problem is when the user click the browsers back button and views the table again. As opposed to showing the items that were originally checked, different items in the list are checked.
To see an example, please go here: http://dev2.njschooljobs.com. Click on the All Schools with Active postings link. That should bringup a modal window with the datatable.Chose Archway, Bayshore Jointure and Berlin twp. then click Apply, then Search Jobs Now button. You will see results for those schools selected. Now click the browsers back button and click on the same link to bring up the modal window with datatable. You will see that what is selected is not what was chosen by the user.
Any help is appreciated.
Thanks,
-Rhon
To see an example, please go here: http://dev2.njschooljobs.com. Click on the All Schools with Active postings link. That should bringup a modal window with the datatable.Chose Archway, Bayshore Jointure and Berlin twp. then click Apply, then Search Jobs Now button. You will see results for those schools selected. Now click the browsers back button and click on the same link to bring up the modal window with datatable. You will see that what is selected is not what was chosen by the user.
Any help is appreciated.
Thanks,
-Rhon
This discussion has been closed.
Replies
So two options I can think of (other than submitting a bug report to Mozilla and waiting for a patch :-) ):
1. Use fnDestroy in window.unload for Firefox, which will destroy the table and put it back into it's original state. But this will slow down the browser's navigation and isn't a brilliant solution.
2. Use a cookie to store what checkboxes are checked, then after the table has been initialised you could run through the checkboxes and ensure that the ones that should be checked, are checked. It's a little bit more work, but sounds like a better solution to me.
Regards,
Allan
Do you have any sample code to achieve the cookie option?
Thanks,
-Rhon
Allan
http://www.datatables.net/examples/api/form.html
It is not possible to sort the checkbox-column
a bug?
Allan
You are right it works here http://datatables.net/examples/plug-ins/dom_sort.html .
but I am also right, it does not work here: http://www.datatables.net/examples/api/form.html
but i see that there is a solution for my problem
kind regards!
Joerg
Allan