emulating the edublogs blog counter

I really like the blog counter on the edublogs homepage, and it also comes with the edu blogs clean theme as well. However, I wan to put it into my theme for the homepage of my WPMU setup, since it is awesome functionality.

Is there a code snippet I can get from you guys to implement this?

Also, creating a plugin for it as a widget might be something worth exploring too.

  • Eric G.
    • The Crimson Coder

    @Saunt Valerian

    You could snag it from the EduBlog Theme from this site!

    Here is what I pulled from my site, but I believe I edited it a little.

    <?php if($multi_site_on == "true"){
    if( function_exists('get_sitestats')) { ?>
    <div class="site-stats"><span><?php _e("Currently powering",TEMPLATE_DOMAIN); ?> <?php
    $stats = get_sitestats();
    $tmp_user_count = number_format ($stats[ 'users' ] );
    $tmp_blog_count = number_format ($stats[ 'blogs' ] );
    print "<strong>" . $tmp_blog_count . " Sites" . "</strong>";
    <?php } } ?>
  • DavidM
    • DEV MAN’s Mascot

    No problem Eric, I went ahead and removed the last div for you. And thanks for posting that, couldn't ask for a better snippet in this scenario.

    @Saunt Valerian, I think you'll find that snippet should take care of that for ya. A plugin for it, likely a widget, would be a rather simple matter too. I'll mention that to some folks over here to see what they think.


Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.