Show/Hide selections not visible on page refresh
Show/Hide selections not visible on page refresh
codeturtle
Posts: 3Questions: 1Answers: 0
When columns are unselected from Show/Hide menu, they are not shown as selected when page is refreshed. I need all of my columns to be visible after a refresh of the page. If I remove this line { data: null, defaultContent: '', orderable: false },
they are all visible after page refresh; however, I then have a duplicate row of column headings.
Please help!
Thanks!
This discussion has been closed.
Answers
Okay, to clarify. I have
stateSave: true
enabled to save the currently viewed data table. I need the selected/unselected table columns to persist across a page refresh. Can someone PLEASE direct me on this. I believe it may have something to do with using sessionStorage, but I'm new at this. Thank you, forever!Per the forum rules, please link to a test case showing the issue so we can debug it.
Allan
After testing was done, this issue was discovered to be caused by using the
scrollX: true
method. Removing this method solved the persistence across page refresh issue. Does anyone know of an alternative to using scrollX? Thanks!-Also, thank you Allan, for the quick response. You are awesome!
Without a test case showing the issue, I'm afraid there is little help we can offer. Please link to the page or create a test case using JSFiddle or http://live.datatables.net .
Allan