Title: datatable js are not loaded
Last modified: November 4, 2016

---

# datatable js are not loaded

 *  Resolved [theking2](https://wordpress.org/support/users/theking2/)
 * (@theking2)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/datatable-js-are-not-loaded/)
 * The Tablepress plug works and it is possible to instert new tables. What doesn’t
   work is user sorting and selecting. The cause being that the required js scripts
   are not included. If I add this to my template it works:
 *     ```
       <script src="/wp-content/plugins/tablepress/js/jquery.datatables.min.js"></script>
       <script type="text/javascript"> jQuery(document).ready(function($){ $('#tablepress-11').dataTable({"order":[],"orderClasses":false,"stripeClasses":['even','odd'],"pagingType":"simple"}); }); </script>
       ```
   
 * But that probably is not the idea of the plugin.
 * How do I make sure that the datatable macros work?

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/datatable-js-are-not-loaded/#post-8397738)
 * Hi,
 * thanks for your post, and sorry for the trouble.
 * Your theme probably does not contain the mandatory call of the `<?php wp_footer();?
   >` function right before the closing `</body>` HTML tag in its footer.php file.
   
   Could you please check that?
 * Regards,
    Tobias
 *  Thread Starter [theking2](https://wordpress.org/support/users/theking2/)
 * (@theking2)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/datatable-js-are-not-loaded/#post-8404631)
 * Danke,
    But that is not the problem. Both Footer.php and get_footer are present.
   The script entries were inserted manually in footer.php and for the specific 
   table #tablerpess-11 the table is shown correctly.
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/datatable-js-are-not-loaded/#post-8405083)
 * Hi,
 * if you had to manually add the two lines from your first post, then something
   was not correct with `wp_footer();`.
    The lines would be added automatically 
   by TablePress if the “Use DataTables” checkbox on the table’s “Edit” screen is
   checked.
 * Does everything work with a WordPress default theme like TwentySixteen?
 * Regards,
    Tobias

Viewing 3 replies - 1 through 3 (of 3 total)

 The topic ‘datatable js are not loaded’ is closed to new replies.

 * ![](https://ps.w.org/tablepress/assets/icon.svg?rev=3192944)
 * [TablePress - Tables in WordPress made easy](https://wordpress.org/plugins/tablepress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tablepress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tablepress/)
 * [Active Topics](https://wordpress.org/support/plugin/tablepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tablepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tablepress/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [9 years, 11 months ago](https://wordpress.org/support/topic/datatable-js-are-not-loaded/#post-8405083)
 * Status: resolved