我有這樣的代碼,使用Facebook的C#API V5和上一個AJAX調用正在運行弄清楚,如果用戶進行身份驗證:開關Facebook的API從V 5到V 6
// Make sure user is logged into Facebook and authroized this application
if (!FacebookWebContext.Current.IsAuthenticated() ||
!FacebookWebContext.Current.IsAuthorized(new[] { "email" }))
{
result.ResultCode = BasicResultCode.NotAuthorized;
return result;
}
var fbuid = FacebookWebContext.Current.UserId;
在V6,Facebook的。 Web名稱空間不存在,FacebookWebContext無處可找。我用什麼來代替上面的代碼?
Facebook.Web不再存在於v6以及FacebookWebClient類中。 – Andrey 2012-07-23 16:20:50
對不起安德烈,你說得對。我正在看我的舊分支。我也從5轉換到6.今晚有一個SDK的製造商的新職位。也許這可以幫助你。 http://blog.ntotten.com/2012/07/23/facebook-apps-and-windows-azure-web-sites-part-1-getting-started/ – 2012-07-24 06:55:36
好吧,讓我們這樣做:我刪除「-1 「並且你刪除了這個不正確的答案 - 雙贏:) – Andrey 2012-07-24 14:00:25