Để chèn nhận xét Facebook vào Blogspot bạn thực hiện các bước sau:
1: Đăng nhập vào giao diện quản lý của Blog
Tại giao diện này bạn chọn mục Mẫu -> Chỉnh sửa HTMl
2: Ấn tổ hợp phím CTRL F tìm thẻ </head>
Bạn chèn đoạn code dưới đây vào trước thẻ </head>
<div id='fb-root'/> <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/vi_VN/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script>
tại data-width="766" chiều rộng khung bình luận
tại data-num-post="8" tổng số nhận xét hiển thị
Bạn có thể thay đổi tùy ý các thông số 766 và 8 trong đoạn code trên
3: Tìm thẻ </body>
Chèn đoạn code bên dưới vào trước thẻ </body>
<div id='fb-root'/> <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/vi_VN/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));</script>
4: Tìm thẻ <b:include data='post' name='post'/>
Thay đoạn code bên dưới vào sau thẻ trên
<b:if cond='data:blog.pageType == "item"'> <script type='text/javascript'> document.write(fbcm); </script> </b:if>
Sau đó bấm lưu mẫu là xong.
xanh lá cây

0 nhận xét:
Post a Comment
Mời bạn nhận xét, vui lòng sử dụng tiếng Việt có dấu. Cảm ơn.