自己的Google Blogger加入FaceBook讚按鈕


先選擇範本→編輯HTML→勾選展開小裝置範本
綠色字-註解
藍色字-原程式碼
紅色字-加入程式嗎?


----加在文章頁身body-----------------------------------------------------------------------------------

    <div class='post-header'>
    <div class='post-header-line-1'/>
    </div>

    <b:if cond='data:blog.metaDescription == &quot;&quot;'>
      <!-- Then use the post body as the schema.org description,
          for good G+/FB snippeting. -->
      <div class='post-body entry-content' expr:id='&quot;post-body-&quot; + data:post.id' itemprop='description articleBody'>
     
<iframe allowTransparency='true' expr:src='&quot;http://www.facebook.com/plugins/like.php?href=&quot; + data:post.url + &quot;&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;font=verdana&amp;colorscheme=light&quot;' frameborder='0' scrolling='no' style='border:none; overflow:hidden; width:450px; height: 65px;'/>

        <data:post.body/> 加在這行上面Body

----加在文章頁腳footer----------------------------------------------------------------------------------

    <div class='post-footer'>


<iframe allowTransparency='true' expr:src='&quot;http://www.facebook.com/plugins/like.php?href=&quot; + data:post.url + &quot;&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;font=verdana&amp;colorscheme=light&quot;' frameborder='0' scrolling='no' style='border:none; overflow:hidden; width:450px; height: 65px;'/>


    <div class='post-footer-line post-footer-line-1'><span class='post-author vcard'>
        <b:if cond='data:top.showAuthor'>

參考:
http://littlebmix.blogspot.tw/2012/07/google-bloggerfacebooklike-button.html
http://design-forces.blogspot.com/2011/10/html-blogger-facebook.html

沒有留言:

張貼留言