HELP! Cannot reinitialise DataTable warning
HELP! Cannot reinitialise DataTable warning
Please help! I know some coding, but clearly not enough to figure out how/where to fix this. Every time I open a page with a table, I always get the error: "DataTables warning...cannot reinitialise DataTable." I've tried several browsers and I always get the same error.
I've spent many hours researching how to fix this, but I can't get a clear answer. I'm trying to create a searchable table for our club's members.
The test page is http://redwoodwriters.org/datatable-test-pg/
Debugger ref#: epapof
Thanks for your help!!
Answers
You are initialising the same DataTable twice. Hence "cannot reinitialise DataTable". A simple forum search would have found this cropping up many times.
Yes, thanks, I had seen that in the forums. There are several "fixes" such as...
~~~~~~~~~~~~
$('#example').dataTable( {
paging: false
} );
$('#example').dataTable( {
searching: false
} );
$('#example').DataTable( {
destroy: true,
searching: false
} );
~~~~~~~~~~~~~~~
destroy: true,
~~~~~~~~~~~~~
... but I'm trying to figure out which will work and where to make changes. I assume this is a change made in one of the TablePress files, but there are dozens. I've been scanning through them, but I can't find a match. Which file should I edit? I'm new to this kind of issue and I don't want to mess up the website.
Thanks for your help.
That's something you would need to ask in the TablePress support channels. TablePress uses DataTables, but is not published or supported by the DataTables project.
Allan