<?php function post_count() { $post_type = 'unternehmer'; $total = wp_count_posts($post_type)->publish; return $total; } add_shortcode(‘unternehmer_anzahl’,’post_count’);
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter