การสร้างปุ๋ม share facebook

Microsoft Office Knowledge Word, Excel, powerpoint, line , โปรแกรมเสริมต่างๆ

Moderators: mindphp, ผู้ดูแลกระดาน

User avatar
thatsawan
PHP VIP Members
PHP VIP Members
Posts: 26740
Joined: 31/03/2014 10:02 am
Contact:

การสร้างปุ๋ม share facebook

Post by thatsawan »

ลิงค์ที่เกี่ยวข้อง
- https://www.mindphp.com/%E0%B8%9A%E0%B8% ... -host.html
- เครื่องมือเช็คผล
-

1. https://developers.facebook.com/docs/pl ... are-button
2015-02-26_1-51-58.png
2015-02-26_1-51-58.png (24.26 KiB) Viewed 397 times

Code: Select all

 <script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script>
              <div id="fb-root"></div>
                <script>(function(d, s, id) {
                  var js, fjs = d.getElementsByTagName(s)[0];
                  if (d.getElementById(id)) return;
                  js = d.createElement(s); js.id = id;
                  js.src = "//connect.facebook.net/th_TH/sdk.js#xfbml=1&appId=330441763797418&version=v2.0";
                  fjs.parentNode.insertBefore(js, fjs);
                }(document, 'script', 'facebook-jssdk'));</script>
2015-02-26_1-52-50.png
2015-02-26_1-52-50.png (60.02 KiB) Viewed 397 times

รูปแบบปุ่ม

Code: Select all

<div class="fb-share-button" data-href="{SHARE_TOPIC}" data-layout="button"></div>
2015-02-26_1-56-50.png
2015-02-26_1-56-50.png (14.24 KiB) Viewed 397 times
กรณีที่เราจะใช้ภาพเเทนรูปแบบปุ่ม

Code: Select all

 <a href="https://www.facebook.com/sharer/sharer.php?u={BOARD_URL}{SHARE_TOPIC_LINE}" onclick="window.open(this.href, 'mywin',
'left=20,top=20,width=100,height=500,toolbar=1,resizable=0'); return false;" ><img src="{T_THEME_PATH}/mtb/images/facebook.png"/></a>
2015-02-26_1-57-28.png
2015-02-26_1-57-28.png (12.67 KiB) Viewed 397 times
  • Similar Topics
    Replies
    Views
    Last post

Return to “Microsoft Office Knowledge & line & Etc”

Who is online

Users browsing this forum: No registered users and 14 guests