Hi samuelk2019,
I am not sure what you mean by ‘saved as a wordpress page’ – do you mean you are copying the Table HTML into the text editor of a WordPress page/post?
If possible can you give us a link to the original (that renders correctly) and a link to the wordpress version you set up?
yes, copying the Table HTML into the text editor
Try removing the whitespace and linebreaks from the Javascript. WordPress inserts line breaks and those will break Javascript. Use the developer tools in Firefox (or Firebug) or Chrome or Safari or IE to check for Javascript errors in the console.
Mark, does the whitespace and linebreaks causes this issue? i think the issue is due to conflict between the scripts and styles with theme vs data table style and script. i think that the data table is not rendering due to conflict with
the script and styles between twenty sixteen theme and data table script and styles.
The solution is we need to properly resolve by enque and registering the scripts/styles.
https://www.seedprod.com/enqueuing-styles-scripts-wordpress/
http://code.tutsplus.com/articles/how-to-include-javascript-and-css-in-your-wordpress-themes-and-plugins–wp-24321
https://datatables.net/forums/discussion/8489/cant-get-datatable-to-show-in-wordpress-page
————————————————–
1. Can you please help me with a code snippet which needs to be inserted on the word press page on how to enqueue the scripts for the single page ?
2. Do we need to add the enqueue with <? php or under the head tag in the html tag
of the word press page.
An example with JS fiddle with source code will of great help…
I think that the data table is not rendering due to conflict with the script and styles between twenty sixteen theme and data table script and styles
That’s why I said to learn how to use the dev tools in browsers to find jQuery errors.
The articles you linked give you what you need to learn about correctly enqueueing scripts into WordPress. Follow those.
Can u please help me with a good link? I read and confused with many of the links, Mark