Tuesday, 10 March 2015

Membuat Tab Komentar Facebook pada Blog

Tampilan sebelum ditambah tab komentar facebook

Tampilan sesudah ditambah tab komentar facebook
 Langkah pertama ialah copy paste kode tepat dibawah <div class='comments' id='comments'>
  • Seperti gambar dibawah ini

Kode Disini >>


<div class='comments-tab' id='fb-comments' onclick='javascript:commentToggle(&quot;#fb-comments&quot;);' title='Comments made with Facebook'>
<img class='comments-tab-icon' src='http://icons.iconarchive.com/icons/uiconstock/socialmedia/512/Facebook-icon.png'/><fb:comments-count expr:href='data:post.url'/> Comments</div>
<div class='comments-tab inactive-select-tab' id='blogger-comments' onclick='javascript:commentToggle(&quot;#blogger-comments&quot;);' title='Comments from Blogger'>
<img class='comments-tab-icon' src='http://www.blogger.com/img/icon_logo32.gif'/> <data:post.numComments/> Comments</div>
<div class='clear'/>
</div>
<div class='comments-page' id='fb-comments-page'>
<b:if cond='data:blog.pageType == &quot;item&quot;'><div id='fb-root'/>
<fb:comments expr:href='data:post.url' num_posts='2' width='430'/></b:if></div>
<div class='comments comments-page' id='blogger-comments-page'>

<script src='http://connect.facebook.net/en_US/all.js#xfbml=1'/><script src='http://code.jquery.com/jquery-latest.js'/><meta content='IDFANPAGEFACEBOOK' property='fb:admins'/><script type='text/javascript'>function commentToggle(selectTab) {$(&quot;.comments-tab&quot;).addClass(&quot;inactive-select-tab&quot;);$(selectTab).removeClass(&quot;inactive-select-tab&quot;);$(&quot;.comments-page&quot;).hide();$(selectTab + &quot;-page&quot;).show();}</script>

<style>.comments-page { background-color: #000000;}#blogger-comments-page { padding: 0px 5px; display: none;}.comments-tab { float: left; padding: 5px; margin-right: 3px; cursor: pointer; background-color: #000000;}.comments-tab-icon { height: 14px; width: auto; margin-right: 3px;}.comments-tab:hover { background-color: #000000;}.inactive-select-tab { background-color: #000000;}</style>
=================================================

Selanjutnya "simpan template" dan silahkan lihat hasilnya.

  • width='430' : Mengatur lebar kolom komentar
  • http://icons.iconarchive.com/icons/uiconstock/socialmedia/512/Facebook-icon.png : Image Icon Logo facebook
  • http://www.blogger.com/img/icon_logo32.gif: Image Icon Logo Blogger
  • IDFANPAGEFACEBOOK: Id Fans Page Facebook Kamu
  • background-color: #000000 : Warna Background untuk kolom komentar
  • background-color: #000000 : Warna tab aktif
  • background-color: #000000 : Warna tab ketika disentuh kursor
  • background-color: #000000 : Warna tab non-aktif
SELAMAT MENCOBA
Comments
2 Comments

2 comments:

Post a Comment

  © Ratna-Always For You The Transformers by Blog Tips And Trick 2009