-2
如何創建類似於雅虎在www.news.yahoo.com上所做的功能? 我的網站有很多文章。當用戶從我的網站登錄到FB時,他在我的網站中訪問的頁面的鏈接應顯示在他的FB Recent活動中。怎麼樣 ?FaceBook與Asp.Net網站集成以獲得最新活動
Functionality :
Your Activity : Shows the News that has been read after logged in.
It Posts in Face Book activities.
Social ON : To allow the script to post in FB
Social OFF : To not allow the script to post in FB
我試圖創建一個Facebook應用程序,並獲得的AppKey。但它沒有提供我需要的功能。我怎樣才能做到這一點 ?
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Sample4.aspx.cs" Inherits="Sample4" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<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/en_US/all.js#xfbml=1";
fjs.parentNode.insertBefore(js, fjs);
} (document, 'script', 'facebook-jssdk'));</script>
<div id="Div1"></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/en_US/all.js#xfbml=1&appId=APPKEY";
fjs.parentNode.insertBefore(js, fjs);
} (document, 'script', 'facebook-jssdk'));</script>
<div id="Div2"></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/en_US/all.js#xfbml=1&appId=APPKEY";
fjs.parentNode.insertBefore(js, fjs);
} (document, 'script', 'facebook-jssdk'));</script>
<form id="form1" runat="server">
<div>
<div class="fb-activity" data-width="300" data-height="300" data-header="false" data-colorscheme="light" data-linktarget="_blank" data-recommendations="false"></div>
</div>
<div class="fb-like" data-href="http://localhost:27531/FaceBook-Integration/Sample4.aspx" data-send="true" data-layout="button_count" data-width="450" data-show-faces="true" data-font="tahoma"></div>
<div class="fb-login-button" data-show-faces="true" data-width="200" data-max-rows="1"></div>
</form>
</body>
</html>