August 13, 2011

Add Delicious Bookmark Buttons With Counter For Blogger


Add Delicious Bookmark Buttons With Counter For Blogger

1.Log in to your dashboard--> desing- -> Edit HTML

2.Click on "Expand Widget Templates"

3.Scroll down to where you see this <data:post.body/> Tag.

4.Copy below code and paste it just after the line <data:post.body/>













<b:if cond='data:blog.pageType == &quot;item&quot;'>
<div class='share-delicious'>
<div class='delicious' id='delic'>0</div>
<div class='delicious-b'><a expr:href='&quot;http://del.icio.us/post?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='blank'>delicious</a></div>
<script type='text/javascript'>
function delic(info) { 
if(!info[0]) return;
var num = info[0].total_posts;
if(!num) return; 
var delic = document.getElementById(&#39;delic&#39;);
delic.innerHTML = &#39;&#39; + num;
delic.style.textIndent = 0;
delic.style.paddingRight= &#39;6px&#39;;
}
</script>
<script expr:src='&quot;http://badges.del.icio.us/feeds/json/url/data?url= &quot; + data:post.url + &quot;&amp;callback=delic&quot;'/>
</div>
</b:if>
<div class='clear'/>

5.Now Scroll down to where you see ]]></b:skin> tag .

6.Copy below code and paste it just before the ]]></b:skin> tag.


Style 1:







.share-delicious{
width:50px;
height:63px;
text-align:center;
}

.delicious{
width:50px;
height: 45px;
background: url(http://2.bp.blogspot.com/_5rlxf3T9Z9U/TAbBZJth5yI/AAAAAAAAHjo/FjCcx7cEcyE/s1600/del+above.png) no-repeat;
font-weight: bold;
font-size: 16px;
font-family:arial;
color:#adadad;
margin:0 auto;
line-height:36px; 
}
.delicious-b{
font-size:10px;
text-transform:none;
color:#FFF;
margin:0 auto;
width:50px;
height:17px;
line-height: 17px;
}
.delicious-b a:link, .delicious-b a:visited{
color:#FFF;
font-weight:normal;
background: url(http://4.bp.blogspot.com/_5rlxf3T9Z9U/TAbLWujRYKI/AAAAAAAAHkI/3H0KFMwuWuo/s1600/del+new.png) no-repeat;
display: block;
text-decoration:none;
}
.delicious-b a:hover{
color:#11788b;
font-weight:normal;
text-decoration:none;
background: url(http://4.bp.blogspot.com/_5rlxf3T9Z9U/TAbLWujRYKI/AAAAAAAAHkI/3H0KFMwuWuo/s1600/del+new.png) no-repeat center -17px;
display: block;
}

Style 2:





.share-delicious{
width:100px;
height:19px;
text-align:center;
font-family:arial;
}
.delicious{
width:46px;
height: 19px;
background: url(http://2.bp.blogspot.com/_5rlxf3T9Z9U/TAbOKzo-xYI/AAAAAAAAHkY/Ex51i4u-vZo/s1600/comp+del.png) no-repeat;
font-weight: bold;
font-size: 13px;
color:#999;
margin:0 auto;
line-height:18px; 
float:left;
}
.delicious-b{
font-size:10px;
text-transform:none;
color:#FFF;
margin:0 auto;
width:50px;
height:17px;
line-height: 17px;
float:left;
}
.delicious-b a:link, .delicious-b a:visited{
color:#FFF;
font-weight:normal;
background: url(http://4.bp.blogspot.com/_5rlxf3T9Z9U/TAbLWujRYKI/AAAAAAAAHkI/3H0KFMwuWuo/s1600/del+new.png) no-repeat;
display: block;
text-decoration:none;
}
.delicious-b a:hover{
color:#11788b;
font-weight:normal;
text-decoration:none;
background: url(http://4.bp.blogspot.com/_5rlxf3T9Z9U/TAbLWujRYKI/AAAAAAAAHkI/3H0KFMwuWuo/s1600/del+new.png) no-repeat center -17px;
display: block;
}


7.Now click on "Save template" you are done.

Cheers.

No comments:

Post a Comment