我有以下代码记录用户,并显示“选择要请求的朋友”对话框(“apprequests”):
<!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml"> <head> <title>Test</title> <script type="text/javascript"> function facebook(){ FB.login(function(response) { if (response.authResponse) { var access_token = FB.getAuthResponse()['accessToken']; FB.ui({ method: 'apprequests',message: 'Sample Title',max_recipients:1 },function(response){ console.log('OK'); }); } },{scope: 'publish_stream'}); } </script> </head> <body> <p><a href="javascript:facebook();">Test</a></p> <div id="fb-root"></div> <script type="text/javascript"> (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/es_LA/all.js#xfbml=0&appId=XXXXXXXXXXXXXX"; fjs.parentNode.insertBefore(js,fjs); }(document,'script','facebook-jssdk')); </script> </body> </html>
该代码正在与所有主流浏览器(Firefox,Chrome,Opera,IE11,Safari for IOS,Android浏览器)配合使用. Safari(对于Mac / PC)是例外:它打开“apprequests”对话框,但对话框出现空白.如果您更改下拉选项(“要邀请的朋友”,然后再次更改为“所有好友”),则会显示好友列表.
任何想法如何解决这个bug?
谢谢!
解决方法
这是
Facebook-API的bug.正如
mark wiltse所述:
We have managed to reproduce this issue and it appears to be a valid bug. We are assigning this to the appropriate team.
没有必要单独处理徒步旅行.你只需要暂停这个任务,直到这个bug被Facebook开发人员解决.