I have a wordpress site that I have uploaded a few custom SQL tables via phpMyAdmin. I’m trying to find a good way of displaying custom queries on my wordpress page. I’ve tried using WP_Datatables, but have run into too many problems with it.
Leave a Reply
You must be logged in to post a comment.
There are some answers to similar questions already on SO; it’s a good idea to search first, i.e. Display data from database inside <table> using wordpress $wpdb
But basically use the WordPress database abstraction layer
wpdb
See https://developer.wordpress.org/reference/classes/wpdb/ for how to use it and see examples, such as below: