2011-11-04 50 views
1

我正在构建一个FB应用程序。我在我的网站上使用JS SDK邀请朋友加入我的FB应用程序。apprequest后的facebook链接

FB.ui({ 
    method: 'apprequests', 
    display: 'iframe', 
    access_token: resp.accessToken, 
    message: 'Please join Bashman' 
}, function(response){ 
    //nothing important here 
}); 

当我邀请一些FB的朋友,然后对他们的通知栏,他们有一个链接,它指向我的应用程序,而不是让他们接受我的邀请。

因此,用户会立即重定向到我的应用程序,而不是有可能首先接受邀请。

我已经做了两个应用程序请求的截图中,第一个是不是我的,它重定向像预期的那样在接受邀请区,它指向:

http://www.facebook.com/?sk=apps&scrollto=confirm_162129010502890&ref=notif&notif_t=app_request

下一个是从我的FB的应用程序,它直接指向我的应用程序,而不是词义区域:

http://apps.facebook.com/orgbashman/?request_ids=293075284044707%2C182589535157904&ref=notif&notif_t=app_request enter image description here

我试图同时使用

REDIRECT_URI

参数

FB.ui({ 
    method: 'apprequests', 
    display: 'iframe', 
    access_token: resp.accessToken, 
    message: 'Please join Bashman', 
    redirect_uri: 'http://www.facebook.com/sk=apps&scrollto=confirm_134863713284095&ref=notif&notif_t=app_request', 
}, function(response){ 
    //nothing important here 
}); 

,但没有运气。

如何让通知区域中的链接指向接受FB应用程序按钮,而不是直接指向我的FB应用程序?

回答

2

不是重写被Facebook做出的博客文章中,我只是去链接到它:

http://developers.facebook.com/blog/post/464/

我有一个应用程序我建立测试了这一点,我得到了相同的结果和你一样。但是,当编辑应用程序设置时,只要我在中禁用了Upgrade to Requests 2.0,请求就会按照您的要求工作。

这里还有什么可能性的详细说明请提供2.0:

http://www.insidefacebook.com/2011/02/16/facebook-introduces-upgrade-to-requests-2-0-to-simplify-re-engagement/