This Recent Posts widget will show not only post titles but also post excerpts or snippets on your blog.
What you can do with this widget:
- display post titles only
- change the number of posts
- change the number of characters of the post snippet/excerpt
- show the post dates
How to add Recent Posts Widget to Blogger:
1. Log in to your Blogger Dashboard >> go to Design >> Add a Gadget >> choose HTML/JavaScript
2. Choose & Copy the code of one of the options below and paste it into the new HTML/JavaScript:
2. Choose & Copy the code of one of the options below and paste it into the new HTML/JavaScript:
Option 1: Recent posts widget with snippets:
_________________________________________________________________________
<div id="hlrpsa">
<script src="http://helplogger.googlecode.com/svn/trunk/recent-posts-with-snippets.js">
</script>
<script>
var numposts = 5;var showpostdate = false;var showpostsummary = true;var numchars = 100;var standardstyling = true;
</script>
<script src="http://your-blog.blogspot.com/feeds/posts/default?orderby=published&alt=json-in-script&callback=showrecentposts">
</script></div>
<div id="rpdr" style="font-family: arial, sans-serif; font-size: 9px;">
<a href="http://how2urdu.blogspot.com/p/how-to-change.html" target="_blank" title="Grab this Recent Posts Widget">Recent Posts Widget</a> by <a href="http://how2urdu.blogspot.com" title="Recent Posts Widget">How2urdu</a></div>
<noscript>Your browser does not support JavaScript!</noscript>
<style type="text/css">
#rpdr {background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj73K_-UQHk0TSDSCGnlxHO5D08j8H6lAOEvTvhhnpqZb0NeCzpKEm90jl5NBjqBqyJW4vyPjC3njI4ApIXgrtMSeHeeyfLMsOSkw5YQg4fxs37TeJhyphenhyphenxqtWynEJoZiKula12C5BDCVuavS/s1600/blogger.png) 0px 0px no-repeat; padding: 1px 0px 0px 19px; height:14px; margin: 5px 0px 0px 0px;line-height:14px;}
#rpdr, #rpdr a {color:#808080;}
#hlrpsa { border-bottom:1px #cccccc dotted; margin-top:-10px; padding-bottom:10px;}
.hlrps a {font-weight:bold; }
.hlrpssumm {}</style>
<script src="http://helplogger.googlecode.com/svn/trunk/recent-posts-with-snippets.js">
</script>
<script>
var numposts = 5;var showpostdate = false;var showpostsummary = true;var numchars = 100;var standardstyling = true;
</script>
<script src="http://your-blog.blogspot.com/feeds/posts/default?orderby=published&alt=json-in-script&callback=showrecentposts">
</script></div>
<div id="rpdr" style="font-family: arial, sans-serif; font-size: 9px;">
<a href="http://how2urdu.blogspot.com/p/how-to-change.html" target="_blank" title="Grab this Recent Posts Widget">Recent Posts Widget</a> by <a href="http://how2urdu.blogspot.com" title="Recent Posts Widget">How2urdu</a></div>
<noscript>Your browser does not support JavaScript!</noscript>
<style type="text/css">
#rpdr {background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj73K_-UQHk0TSDSCGnlxHO5D08j8H6lAOEvTvhhnpqZb0NeCzpKEm90jl5NBjqBqyJW4vyPjC3njI4ApIXgrtMSeHeeyfLMsOSkw5YQg4fxs37TeJhyphenhyphenxqtWynEJoZiKula12C5BDCVuavS/s1600/blogger.png) 0px 0px no-repeat; padding: 1px 0px 0px 19px; height:14px; margin: 5px 0px 0px 0px;line-height:14px;}
#rpdr, #rpdr a {color:#808080;}
#hlrpsa { border-bottom:1px #cccccc dotted; margin-top:-10px; padding-bottom:10px;}
.hlrps a {font-weight:bold; }
.hlrpssumm {}</style>
_________________________________________________________________________
Option 2: Recent Posts Widget Showing Post Titles Only:
_________________________________________________________
<div id="hlrpsb">
<script style="text/javascript" src="http://helplogger.googlecode.com/svn/trunk/recent-posts-with-titles-only.js"></script>
<script style="text/javascript">var numposts = 10;var showpostdate = false;var showpostsummary = false;var numchars = 100;var standardstyling = true;</script>
<script src="http://your-blog.blogspot.com/feeds/posts/default?orderby=published&alt=json-in-script&callback=showrecentposts"></script></div>
<div style="font-family: arial, sans-serif; font-size: 9px;" id="rpdr"><a href="http://how2urdu.blogspot.com/p/how-to-change.html" title="Grab this Recent Posts Widget" target="_blank">Recent Posts Widget</a> by <a href="http://how2urdu.blogspot.com" title="Recent Posts Widget">How2urdu</a></div><noscript>Oops! Make sure JavaScript is enabled in your browser.</noscript>
<style type=text/css>
#rpdr {background: url( https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj73K_-UQHk0TSDSCGnlxHO5D08j8H6lAOEvTvhhnpqZb0NeCzpKEm90jl5NBjqBqyJW4vyPjC3njI4ApIXgrtMSeHeeyfLMsOSkw5YQg4fxs37TeJhyphenhyphenxqtWynEJoZiKula12C5BDCVuavS/s1600/blogger.png ) 0px 0px no-repeat; padding: 1px 0px 0px 19px; height:14px; margin: 5px 0px 0px 0px;line-height:14px;}
#rpdr, #rpdr a {color:#808080;}
#hlrpsb { }
.bbrecpost2 {
padding-top:6px;
padding-bottom:6px;
border-bottom: 1px #cccccc dotted; }
</style>
<script style="text/javascript" src="http://helplogger.googlecode.com/svn/trunk/recent-posts-with-titles-only.js"></script>
<script style="text/javascript">var numposts = 10;var showpostdate = false;var showpostsummary = false;var numchars = 100;var standardstyling = true;</script>
<script src="http://your-blog.blogspot.com/feeds/posts/default?orderby=published&alt=json-in-script&callback=showrecentposts"></script></div>
<div style="font-family: arial, sans-serif; font-size: 9px;" id="rpdr"><a href="http://how2urdu.blogspot.com/p/how-to-change.html" title="Grab this Recent Posts Widget" target="_blank">Recent Posts Widget</a> by <a href="http://how2urdu.blogspot.com" title="Recent Posts Widget">How2urdu</a></div><noscript>Oops! Make sure JavaScript is enabled in your browser.</noscript>
<style type=text/css>
#rpdr {background: url( https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj73K_-UQHk0TSDSCGnlxHO5D08j8H6lAOEvTvhhnpqZb0NeCzpKEm90jl5NBjqBqyJW4vyPjC3njI4ApIXgrtMSeHeeyfLMsOSkw5YQg4fxs37TeJhyphenhyphenxqtWynEJoZiKula12C5BDCVuavS/s1600/blogger.png ) 0px 0px no-repeat; padding: 1px 0px 0px 19px; height:14px; margin: 5px 0px 0px 0px;line-height:14px;}
#rpdr, #rpdr a {color:#808080;}
#hlrpsb { }
.bbrecpost2 {
padding-top:6px;
padding-bottom:6px;
border-bottom: 1px #cccccc dotted; }
</style>
_____________________________________________________
3. Change 5 (option 1) and 10 (option 2) with the number of posts you want to show. Change false to true if you want the posts dates to appear, and change 100 (option 1) if you want more characters to be displayed.
Don't forget to change your-blog text with the name of your blog or if you have a custom domain change all the bolded line with your address like in this example:
Don't forget to change your-blog text with the name of your blog or if you have a custom domain change all the bolded line with your address like in this example:
_________________________________________
http://www.your-site.com/feeds/posts/default....
_____________________________________________________
4. Save your widget. That's it!! Enjoy
No comments:
Post a Comment