Accordion widget for featured posts with thumbnails
In SimplexPro template design by Simplex desing there’s an accordion widget which show featured posts with thumbnails. This widget help you to publicize posts of a important label of your blog.
This widget only work with one label and thumbnails will only be view if you offer a full feed. To have it in your blog, just follow these steps:
1. Login your Blogger account and go to “Layout” > “Edit html”
2. Place this css just before ]]></b:skin>
.accordion {
float:left;
width: 260px;
border-bottom: solid 1px #c4c4c4;
}
.accordion h4 {
background: #e9e7e7 url(http://www.webdesignerwall.com/demo/jquery/images/arrow-square.gif) no-repeat right -51px;
padding: 7px 15px;
margin:0;
font: bold 120%/100% Arial, Helvetica, sans-serif;
border-top: solid 1px #c4c4c4;
border-bottom: none;
cursor: pointer;
}
.accordion h4:hover {
background-color: #e3e2e2;
}
.accordion h4.active {
background-position: right 5px;
}
.accordion p {
background: #f7f7f7;
margin: 0;
padding: 10px 15px 20px;
}
3. Put this code before </head>
<script src='http://contact.dinhquanghuy.googlepages.com/jquery.js' type='text/javascript'/>
<script type='text/javascript'>
$(document).ready(function(){
$(".accordion h4:first").addClass("active");
$(".accordion p:not(:first)").hide();
$(".accordion h4").click(function(){
$(this).next("p").slideToggle("slow")
.siblings("p:visible").slideUp("slow");
$(this).toggleClass("active");
$(this).siblings("h4").removeClass("active");
});
});
</script>
Save your template.
4. Go to “Layout” and add a new Html widget where you’ll put all this code: replace words in bold with correct informations.
<script language='javascript'>
imgr = new Array();
imgr[0] = "http://sites.google.com/site/fdblogsite/Home/nothumbnail.gif";
showRandomImg = true;
jimgwidth = 220;
jimgheight = 120;
jfntsize = 12;
jacolor = "#E67C15";
jaBold = true;
jtext = "Comments";
jshowPostDate = true;
sumtitle = 25;
jsummaryPost = 200;
summaryFontsize = 12;
summaryColor = "#000";
numposts = 6;
label = "Your label";
home_page = "http://yourblog.blogspot.com/";
</script>
<div class='accordion'>
<script src='http://simplexdesign.googlecode.com/files/j-label-fix.js' type='text/javascript'></script>
</div>
Save the widget, go to have a look and enjoy this accordion widget showing one label featured posts with thumbnails!
hemmm...nice post, i like it..!!! please visit me on http://kianhome.blogspot.com/
RépondreSupprimerThanks man great post. News Update
RépondreSupprimerWaw... nice... I like this
RépondreSupprimerWhen I get really cool! Thanks, keep up the good work with the incredible lessons. :)
RépondreSupprimerCe commentaire a été supprimé par l'auteur.
RépondreSupprimer