Add Random Post Widget to Blogger
Friends, here is simple method for adding the random posts in your blog... So follow the following steps.
Here are the Steps
Step 1. Log in to Blogger Dashboard, and select Template > Edit HTML (click on Proceed button if needed)
Step 2. Select "Expand Widget Templates"
Step 3. Now hold CTRL + F
Find the following in the box as the given fig.
]]>
Step 4. Just above it, paste the code below :
#random-posts img{float:left;margin-right:10px;border:1px solid #999;background:#FFF;width:36px;height:36px;padding:3px}
Step 5. Save Template.
Step 6. Go to Layout, click on Add a Gadget
Step 7. Add a new HTML/JavaScript Gadget
Step 8. Paste the following code in the empy HTML box:
var rdp_numposts=5;
var rdp_snippet_length=150;
var rdp_info='yes';
var rdp_comment='Comments';
var rdp_disable='Comments Disabled';
var rdp_current=[];var rdp_total_posts=0;var rdp_current=new Array(rdp_numposts);function totalposts(json){rdp_total_posts=json.feed.openSearch$totalResults.$t}document.write('
function random_posts(json){for(var i=0;i]*>/g,"");if(rdp_get_snippet.length');document.write('');document.write('');if(rdp_info=='yes'){document.write(''+rdp_postdate.substring(8,10)+'/'+rdp_postdate.substring(5,7)+'/'+rdp_postdate.substring(0,4)+' - '+rdp_commentsNum)+''}document.write('')}};getvalue();for(var i=0;i<\/script>')};
Note: U can change the value of Number of posts by the changing above blue line..
Step 9: Click Save...Now random post widget is in your blogger.
IF u have any problem ask me through comments