Open/Close Menu WordPress & WooCommerce Plugin & Theme Development

Use the following snippet to track post views on your WordPress blog. The first thing you want to do is add this snippet to the functions.php of your WordPress theme. Follow step 1. and step 2. to track and display the number of views for each post.

place this snippet below within the single.php inside the WordPress loop:

To display the number of views within your posts. Place this snippet within the loop:

© 2017 CodeNegar | Made with love.
Follow us: