adf.ly - shorten links and earn money!

How To Add Total Posts and Comments Widget Of Your Blog

Add Total Posts and Comments Widget Of Your Blog. The widget is look alike below screenshot.


You wanna add this widget on your blog. You can add this widget, just in 3 steps. Follow this steps :


1. Go to your Dashboard > Design > Page Element > Add a Gadget > HTML/Javascript.

2.  Copy paste this code below, in it.

<!--START-http://place2how-to.blogspot.com/-->
<script style="text/javascript">
function totalPosts(json) {
document.write('Total Posts: <b>'   json.feed.openSearch$totalResults.$t   '</b><br>');
}
function totalComments(json) {
document.write('Total Comments: <b>'   json.feed.openSearch$totalResults.$t   '</b><br>');
}
</script>
<script src=" /feeds/posts/default?alt=json-in-script&callback=totalPosts"></script>
<script src=" /feeds/comments/default?alt=json-in-script&callback=totalComments"></script>
<!--END-http://place2how-to.blogspot.com/-->

3. Save it. DONE!


If you want to align the widget at the center. Add this code below after, <!--START-http://place2how-to.blogspot.com/-->

<div style="text-align: center;">

ENJOY!!

1 comment:

  1. Hello There. Ӏ founԁ your blоg using msn.
    This is a νerу ωell written аrtісlе.

    I'll make sure to bookmark it and return to read more of your useful info. Thanks for the post. I'll definitely retuгn.



    Feеl free to surf to my web-site how to recondition furniture
    My blog - how to rehabilitate furniture for profit

    ReplyDelete

Drop your comment. Ask or suggestion.

Join us on Faceboook Page too.