• GuestPost Guidelines
  • Contact Us

Delete Twitter,Facebook Account

  • HOME
  • Affiliate
  • Blogging
  • How To
  • SEO
  • Reviews
  • Write Guest Post
  • Hostgator Discount

How to show 10 posts instead of 5 posts in blogger

Tweet

We all always tried to show more recent Posts but we always failed because bloggers Feed Widget it only shows 5 posts only but today I m going to tell you how to show 10 recent posts or more. for this you just have add a simple JavaScript. So now lets get Started.

Follow the Following steps:
1. Login in to your blogger dashboard .
2. Click on the layout Link.
3. Click on Add a Gadget Link.
4. Then Select HTML/JavaScript Add .
5. Paste the Following code and your Done.

To show 10 posts instead of 5 posts in blogger

How we show 10 posts instead of 5 posts in blogger

<script>
function rpundefinedjson) {
document.writeundefined’<ul>’);

for undefinedvar i = 0; i < numposts; i++) {
document.writeundefined’<li>’);
var entry = json.feed.entry[i];
var posttitle = entry.title.$t;
var posturl;

if undefinedi == json.feed.entry.length) break;

for undefinedvar k = 0; k < entry.link.length; k++) {
if undefinedentry.link[k].rel == ‘alternate’) {
posturl = entry.link[k].href;
break;
}
}

posttitle = posttitle.linkundefinedposturl);
var readmorelink = “undefinedmore)”;
readmorelink = readmorelink.linkundefinedposturl);
var postdate = entry.published.$t;
var cdyear = postdate.substringundefined0,4);
var cdmonth = postdate.substringundefined5,7);
var cdday = postdate.substringundefined8,10);
var monthnames = new Arrayundefined);
monthnames[1] = “Jan”;
monthnames[2] = “Feb”;
monthnames[3] = “Mar”;
monthnames[4] = “Apr”;
monthnames[5] = “May”;
monthnames[6] = “Jun”;
monthnames[7] = “Jul”;
monthnames[8] = “Aug”;
monthnames[9] = “Sep”;
monthnames[10] = “Oct”;
monthnames[11] = “Nov”;
monthnames[12] = “Dec”;

if undefined”content” in entry) {
var postcontent = entry.content.$t;
} else if undefined”summary” in entry) {
var postcontent = entry.summary.$t;
} else
var postcontent = “”;
var re = /<S[^>]*>/g;
postcontent = postcontent.replaceundefinedre, “”);
document.writeundefinedposttitle);

if undefinedshowpostdate == true) document.writeundefined’ – ‘ + monthnames[parseIntundefinedcdmonth,10)] + ‘ ‘ + cdday);

if undefinedshowpostsummary == true) {
if undefinedpostcontent.length < numchars) {
document.writeundefinedpostcontent);
} else {
postcontent = postcontent.substringundefined0, numchars);
var quoteEnd = postcontent.lastIndexOfundefined” “);
postcontent = postcontent.substringundefined0,quoteEnd);
document.writeundefinedpostcontent + ‘…’ + readmorelink);
}
}
document.writeundefined’</li>’);
}
document.writeundefined’</ul>’);

}
</script>

<script>
var numposts = 10;
var showpostdate = false;
var showpostsummary = false;
var numchars = 100;
</script>

<script src=”http://YOURBLOG.blogspot.com/feeds/posts/default?orderby=published&alt=json-in-script&callback=rp”></script>

<br />
<div></div><p style=”text-align:center;”><a href=”http://www.best2know.info/2010/04/how-to-show-10-posts-instead-of-5-posts.html” title=”Grab this wiget” target=’_blank’><b>Grab this Widget<b></b></b></a></p>

In the Above code change the

YourBlog.blogspot.com

with your link of your site or of your custom domain.

And if you want to show more than 10 posts then change the number which is

in red color to the number of how much posts you want to show.

These Articles can be helpful to you

  1. Blogger SEO Tips:Display BlogTitle after a PostTitle in Blogger
  2. Publish Your Blog Posts to Facebook FanPage Automatically
  3. Top 5 Tips to Write SEO Friendly Blog Post
  4. How to add Orkut Share button
  5. [How-to] Add Digg button to Blogger Post

Tagged as: Blogspot Hacks

Comments on this entry are closed.

Previous post: Protect your WordPress Blog using this Security Tips

Next post: How To Customize Google Custom Search Engine Watermark Image And Search Button


  • We are Open for Guest posting at ShoutGeek

  • Stay Connected

    Subscribe FREE updates on your Email | RSS

    Like us on Facebook
    Circle us on Google+

    PHP, ASP.NET Web Development

  • recent posts

    • [How-to] Delete Google Account with Google Plus Profile
    • Secret Facebook Emoticons for Chat: Uses and Benefits
    • How to use Twitter to promote your business
    • Few uncomfortable truths about social media
    • Top iPhone and iPad games 2012: The App Store is Vast
  • Make Money Online

    • Best Social bookmarking Site
    • Get traffic to your Blog
    • Top Best Facebook Games
    • Increase Facebook Likes
  • Blogging Tips

    • Leverage Browser Caching
    • Import Facebook Contacts
    • AutoBlogging
    • How to Get Backlinks
  • Earn More Money

    • Google Chrome Themes
    • How to make money by selling Domains
    • SEO Tips
    • Recover Windows Administrator Password
  • Blogroll

    • Internet Marketing Blog

Copyright 2008-2011 - How to Blog || Sitemap