Farhan Share - Sobat farhan pada postingan kali ini farhan akan berbagi tentang Cara Membuat widget Follow Us di blog. Sebenarnya apa sih sobat farhan fungsi dan kegunaan dari widget Follow Us ini? Ya, sobat widget ini menurut saya pribadi mempunyai beberapa keunggulan dan kelebihan seperti desain widgetnya yang menarik dan kreatif, dan juga berfungsi bagi sobat yang mungkin ingin mempromosikan fan page Twitter atau Facebook blog sobat agar terlihat bagus tampilanya, dan agar banyak yang menjadi Fans dan Followersnya. Baik, sobat farhan di bawah ini sudah saya persiapkan script widget Follow Us dan cara memasangnya lengkap, di simak baik-baik ya.
1. Login ke Blogger.
2. Pilih Tata Letak.
3. Pilih Add Gadget.
4. Pilih HTML/JavaScript.
5. Letakkan kode di bawah ini ke dalam box "konten".
<script type='text/javascript'>
window.setTimeout(function() {document.body.className = document.body.className.replace('loading', '');
}, 10);
</script>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'/>
<script type='text/javascript'>
//<![CDATA[
$(document).ready(function() {
$('#social li').each(function() {
var $li = $(this);
var title = $li.find('a').attr('title');
$li.find('a').removeAttr('title');
$('<span class="tooltip"/>').text(title).appendTo($li.find('a')).hide();
$li.find('a').mouseover(function() {
var top = $(this).position().top;
var left = $(this).position().left;
$(this).find('span').fadeIn()({
top: top,
left: left
}, 'slow');
});
$li.find('a').mouseout(function() {
$(this).find('span').fadeOut('slow');
});
});
});
//]]>
</script>
<style>
#social {
width: 98%;
height: 45px;
margin: 0;
padding: 10px 5px 5px 30px;
list-style: none;
border-right:solid 1px #853529;
position: relative;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjiwVMWkc1ZgoKPmCZLv_I5ml9fC8mxbRr55Yg5lMnyU5-IyN2Jdfdvc_kTYeq5GOq1J1i4e6hRGfiv4nbcC0AUX-a3Pd_T6K0mpF7GMkPKQlxvRXyWyzW0gq1r8NyyRFhtRlkFKPAg5us/) no-repeat left top;
}
#social p{
font-size:1.5em;
color:#FFFB98;
font-weight:bold;
float:left;
margin: 10px 10px 0 0;
text-shadow: 1px 1px 0px #000000;
filter: dropshadow(color=#000000, offx=1, offy=1);
}
.abt{
font-size:0.8em;
color:#787878;
float:right;
margin: 0 -30px 0 0;
text-shadow: 1px 1px 0px #ffffff;
filter: dropshadow(color=#ffffff, offx=1, offy=1);
}
#social li {
width: 32px;
height: 32px;
float: left;
margin-right: 3px;
}
#social li a {
float: left;
display: block;
width: 100%;
height: 100%;
text-indent: -1000em;
background-repeat: no-repeat;
text-decoration: none;
}
#social #rss {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj59irF0nwcu_gPrpcC9H4rximdJB0wS6AmZW5ay_3XwlrdpdeRV4PCu0ccBX0B-6KVj3fCe8yhBJ9Sz4v_ne_ykvg3xojlanrDfD3bB5SFZVi5L43eb99DuRQLPBsvgR9BLmizwt35Gh4/s400/allblogtools_rss.png);
}
#social #facebook {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_Ju2T8REZpkeU2K3MeAOapC6ew2-eR_Iyw2XJnkoxuwUKlnk6i12NIt4nX19tQQaaE2XrL-XJ8YgUQfJ6foGcrLsswUu5Gi6_HlCkVTO_M7rLxK9Ni0XqSuWTqsMpUkM5tuNAPFipIXU/s400/allblogtools_facebook.png);
}
#social #twitter {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhuU1q4M1hSwgcDClmjEXr6SsepNMFcFx2tAbQN_nA3Hsq6JTPP7s08rG68ecpQb7fZjOSIwYbx-4bdFDav9i67pPd0rqkeLrDtCu5XSl2dK9ZiwlX3V9GUqYb-WLNidHiXFEKA7I1JnXQ/s400/allblogtools_twitter.png);
}
#social #mail {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhe2zzagsPSmo5MMy2R6kAbXvm84yWv3QwdC6ZYov56fygRDGHHcPON5c0faIhblopDQr8TfBUAsiSdTxwVE-ULwDAtAcdTALSzgbRz3j7sUnZq0ophHv0cepjXqJu2CK3Uw_CCuGJEP2o/s400/allblogtools_email.png);
}
span.tooltip {
background: #575757;
padding: 3px;
display: block;
width: 140px;
border: 1px solid #000000;
position: absolute;
margin-top:-40px;
color: #F0F0F0;
font-size:10px;
text-indent: 0;
font: Arial, sans-serif;
text-align: center;
-webkit-box-shadow: inset 2px 2px 2px #616161;
-moz-box-shadow: inset 2px 2px 2px #616161;
box-shadow: inset 2px 2px 2px #616161;
-moz-border-radius: 5px;
border-radius: 5px;
}
</style>
<ul id="social">
<p>Follow Us </p>
<li><a href="http://BLOG-NAME.blogspot.com/feeds/posts/default?alt=rss" id="rss" title="Follow Our Feeds">Rss</a></li>
<li><a href="http://feedburner.google.com/fb/a/mailverify?uri=farhanshare" id="mail" title="Subscribe To Our News Letter">Mail</a></li>
<li><a href="https://www.facebook.com/farhanshare" id="facebook" title="Be Our FaceBook Fan">Facebook</a></li>
<li><a href="http://twitter.com/farhanshare" id="twitter" title="Follow Us On Twitter">Twitter</a></li>
</ul>
}, 10);
</script>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'/>
<script type='text/javascript'>
//<![CDATA[
$(document).ready(function() {
$('#social li').each(function() {
var $li = $(this);
var title = $li.find('a').attr('title');
$li.find('a').removeAttr('title');
$('<span class="tooltip"/>').text(title).appendTo($li.find('a')).hide();
$li.find('a').mouseover(function() {
var top = $(this).position().top;
var left = $(this).position().left;
$(this).find('span').fadeIn()({
top: top,
left: left
}, 'slow');
});
$li.find('a').mouseout(function() {
$(this).find('span').fadeOut('slow');
});
});
});
//]]>
</script>
<style>
#social {
width: 98%;
height: 45px;
margin: 0;
padding: 10px 5px 5px 30px;
list-style: none;
border-right:solid 1px #853529;
position: relative;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjiwVMWkc1ZgoKPmCZLv_I5ml9fC8mxbRr55Yg5lMnyU5-IyN2Jdfdvc_kTYeq5GOq1J1i4e6hRGfiv4nbcC0AUX-a3Pd_T6K0mpF7GMkPKQlxvRXyWyzW0gq1r8NyyRFhtRlkFKPAg5us/) no-repeat left top;
}
#social p{
font-size:1.5em;
color:#FFFB98;
font-weight:bold;
float:left;
margin: 10px 10px 0 0;
text-shadow: 1px 1px 0px #000000;
filter: dropshadow(color=#000000, offx=1, offy=1);
}
.abt{
font-size:0.8em;
color:#787878;
float:right;
margin: 0 -30px 0 0;
text-shadow: 1px 1px 0px #ffffff;
filter: dropshadow(color=#ffffff, offx=1, offy=1);
}
#social li {
width: 32px;
height: 32px;
float: left;
margin-right: 3px;
}
#social li a {
float: left;
display: block;
width: 100%;
height: 100%;
text-indent: -1000em;
background-repeat: no-repeat;
text-decoration: none;
}
#social #rss {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj59irF0nwcu_gPrpcC9H4rximdJB0wS6AmZW5ay_3XwlrdpdeRV4PCu0ccBX0B-6KVj3fCe8yhBJ9Sz4v_ne_ykvg3xojlanrDfD3bB5SFZVi5L43eb99DuRQLPBsvgR9BLmizwt35Gh4/s400/allblogtools_rss.png);
}
#social #facebook {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_Ju2T8REZpkeU2K3MeAOapC6ew2-eR_Iyw2XJnkoxuwUKlnk6i12NIt4nX19tQQaaE2XrL-XJ8YgUQfJ6foGcrLsswUu5Gi6_HlCkVTO_M7rLxK9Ni0XqSuWTqsMpUkM5tuNAPFipIXU/s400/allblogtools_facebook.png);
}
#social #twitter {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhuU1q4M1hSwgcDClmjEXr6SsepNMFcFx2tAbQN_nA3Hsq6JTPP7s08rG68ecpQb7fZjOSIwYbx-4bdFDav9i67pPd0rqkeLrDtCu5XSl2dK9ZiwlX3V9GUqYb-WLNidHiXFEKA7I1JnXQ/s400/allblogtools_twitter.png);
}
#social #mail {
background-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhe2zzagsPSmo5MMy2R6kAbXvm84yWv3QwdC6ZYov56fygRDGHHcPON5c0faIhblopDQr8TfBUAsiSdTxwVE-ULwDAtAcdTALSzgbRz3j7sUnZq0ophHv0cepjXqJu2CK3Uw_CCuGJEP2o/s400/allblogtools_email.png);
}
span.tooltip {
background: #575757;
padding: 3px;
display: block;
width: 140px;
border: 1px solid #000000;
position: absolute;
margin-top:-40px;
color: #F0F0F0;
font-size:10px;
text-indent: 0;
font: Arial, sans-serif;
text-align: center;
-webkit-box-shadow: inset 2px 2px 2px #616161;
-moz-box-shadow: inset 2px 2px 2px #616161;
box-shadow: inset 2px 2px 2px #616161;
-moz-border-radius: 5px;
border-radius: 5px;
}
</style>
<ul id="social">
<p>Follow Us </p>
<li><a href="http://BLOG-NAME.blogspot.com/feeds/posts/default?alt=rss" id="rss" title="Follow Our Feeds">Rss</a></li>
<li><a href="http://feedburner.google.com/fb/a/mailverify?uri=farhanshare" id="mail" title="Subscribe To Our News Letter">Mail</a></li>
<li><a href="https://www.facebook.com/farhanshare" id="facebook" title="Be Our FaceBook Fan">Facebook</a></li>
<li><a href="http://twitter.com/farhanshare" id="twitter" title="Follow Us On Twitter">Twitter</a></li>
</ul>
Catatan : Ganti kode yang berwarna Biru dengan ID Feedburner blog sobat.
Catatan : Ganti kode yang berwarna Merah dengan URL Facebook blog sobat.
Catatan : Ganti kode yang berwarna Ungu dengan URL Twitter blog sobat.
6. Klik "Save" dan Selesai
Demikian sobat farhan artikel tentang Membuat widget follow us dengan jquery di blog, semoga bermanfaat, bila ada pertanyaan comment di bawah.
Script Source : BlazerBlog
EmoticonEmoticon