How To Add Top Authors Widget For Blogger

Posted by Lasantha Bandara on June 4th, 2009 File Under : gadget, google, widget2 Comments

If you want to start showing all your top author’s name and the number of posts they have made in the sidebar,follow the easy steps below.

1.Login to your dashboard--> layout- ->Page Elements

2.Click on 'Add a Gadget' on the sidebar.

3.Select 'HTML/Javascript' and add the code given below and click save.

<script type="text/javascript">
function pipeCallback(obj) {
document.write('<ol>');
var i;
for (i = 0; i < obj.count ; i++)
{
var href = "'" + obj.value.items[i].link + "'";
if(obj.value.items[i].link == "")
var item ="<li>" + obj.value.items[i].title + "</li>";
else
var item = "<li>" + "<a href=" + href + ">" + obj.value.items[i].title + "</a> </li>";
document.write(item);
}
document.write('</ol>');
}
</script>
<script src="http://pipes.yahoo.com/pipes/pipe.run?_render=json&_callback=pipeCallback&_id=0914c284eb9e2a1e7e1e903896990b6f&url=http%3A%2F%2FYOURBLOGNAME.BLOGSPOT.COM&num=10" type="text/javascript"></script>

Note : Remember to replace YOURBLOGNAME.BLOGSPOT.COM with your blogger URL without adding http://

Now you are done.

File Under : gadget, google, widget

2 Responses to “How To Add Top Authors Widget For Blogger”

  1. widgetblogger.co.cc says:

    Excellent post keep it up dude!

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.