How to get The Loop working with $wpdb->get_results()
1 2 3 4 5 6 7 8 9 10 | <?php $data_ads = $wpdb->get_results("SELECT * FROM table_name"); global $ads; foreach ($data_ads as $ads) { echo $ads->image; } ?> |
1 2 3 4 5 6 7 8 9 10 | <?php $data_ads = $wpdb->get_results("SELECT * FROM table_name"); global $ads; foreach ($data_ads as $ads) { echo $ads->image; } ?> |