Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- global $wpdb;
- $posts = $wpdb->get_results( $wpdb->prepare("SELECT comment_ID, comment_author, comment_date FROM {$wpdb->comments}") );
- foreach ( $posts as $item ) {
- echo $item->comment_author;
- }
- // https://codex.wordpress.org/Displaying_Posts_Using_a_Custom_Select_Query
Advertisement
Add Comment
Please, Sign In to add comment