Using WP-Stats functions with Jetpack?
-
Previously, when using the old wp-stats, I used a script I found in the codex to display stats in the sidebar.
I know that jetpack has a Top Posts and Pages widget, however I need to put Most read into a tab box, and do other customization.
Is there a shortcode or script I can use?
This is what I used to use, will it still work properly?
[php]
if ( function_exists(‘get_stats_exclude_home’) && $top_posts = get_stats_exclude_home(-1,5) ) : ?>-
<?php foreach ( $top_posts as $p ) : ?>
- “><?php echo get_the_title($p[‘post_id’]) ?>
<?php endforeach; ?>
<?php endif;
[/php]I liked this script because I could exclude home, and indicate days, and customize the markup.
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Using WP-Stats functions with Jetpack?’ is closed to new replies.