Search and sort wont load when i use wordpress theme (brand)
Search and sort wont load when i use wordpress theme (brand)
I am a total noob when it comes to coding datatables but i figured out how to code the tables using jsfiddle and stuff. Right now when i get the file up locally and not put onto the text editor, the datatable shows all the records and i can sort and search. However it does not display on the brand theme for wordpress and just shows all the tables without any of the scripts on even though they are loaded.
Thanks for your help in advance.
By the way im using the jsfiddle libraries so...
This question has an accepted answers - jump to answer
Answers
just thought id give an update and say im modifying this part of the website
https://test-titanium.tk/database/
A had a quick look at your page and I saw some minor errors in the html, for example on line 464:
The
</p>
should not be there (after initDatatable();) and neither the<p>
on the next line.The same thing on line 771:
I don't know if this is causing your problems, as I have not tested it.
The browser's console shows these errors:
The first error is here:
Looks like you have
<p>
tags throughout your script. This is causing the errors and not executing the Datatables init code.Looks like you may have other syntax errors. You can run your page through the WC3 Validator:
https://validator.w3.org/
Minimally you will need to remove the
<p>
tags.Kevin
@kthorngren yea i have noticed that as well but for some reason when i delete it, it gets rid of the whole table. ill give it a try tonight and see if it works
Found the answer!! So when you leave whitespace within wordpress it creates those <P> tags. wow thats such a pain >.>