count comment

Please visit Source Site
#wordpress #wp #php #snippet #coding
function wpb_comment_count($post_id) { $comments_count = wp_count_comments($post_id); $message = ‘’.$comments_count->approved.’’ ; return $message; } add_shortcode(‘wpb_total_comments’,’wpb_comment_count’); add_filter(‘widget_text’,’do_shortcode’);
The post count comment appeared first on GenerateWP.
Please visit Source Site