This snippet will pull the total number of published posts in a WordPress Website
echo wp_count_posts()->publish;
Need a helping hand in fixing your website issues?
If you are facing any problems in implementing these code snippets and tutorials, you can hire us to fix your website issues.
Hire Us