Рет қаралды 13,768
You might have face problem displaying Post Views for the CPT especially if your website is a newspaper, property listing or classified. In this tutorial, i will show you how to create it with few lines of code in JetEngine Crocoblock.
In addition to that it covers how to show total number of CPT.
Code to be inserted in Child theme:
$meta_values = get_post_meta( get_the_ID(), "posts-count", true);
$v2 = (int)$meta_values + 1;
update_post_meta( get_the_ID(), 'posts-count', $v2);
Download Elementor:
elementor.com/?ref=16401
Download Crocoblock:
crocoblock.com/?ref=4088
Need to build dynamic websites?
softemblems.com
Follow me on Social Media
Facebook : / mxtchamkani
Instagram : / moxet
Twitter : / sokaniwaal
Track: Peruvian Woods - Dave Osorio [Audio Library Release]
Music provided by Audio Library Plus
Watch: • Peruvian Woods - Dave Osorio | Free B...
Free Download / Stream: alplus.io/peruvian-woods