我有一个使用AS3 Graph API的Flash应用程序,只要Facebook打开请求的对话(购买,发布,邀请)。不幸的是,这些对Facebook.ui的调用似乎永远不会导致相应的回调方法被触发。
例如,下面的方法成功打开了Facebook帖子对话框,但_fbPostResponse()方法永远不会被响应。
非常感谢任何帮助!
// Sample Code - This method should post a link to the user's wall
// The _fbPostResponse method should be invoked by Facebook when this action is complete.
function post(link:String, pic:String, name:String, caption:String, desc:String):void {
trace("Post to wall");
var params:Object = {
link:link,
picture:pic,
name:name,
caption:caption,
description:desc
}
Facebook.ui("feed", params, _fbPostResponse);
}
// The _fbPostResponse method should be invoked by Facebook when this action is complete.
function _fbPostResponse(response:Object, fail:Object):void
{
trace("Post response!");
}
答案 0 :(得分:0)
Facebook.ui的回调功能只需要一个参数。请尝试以下方法:
// The _fbPostResponse method should be invoked by Facebook when this action is complete
function _fbPostResponse(response:Object):void
{
trace("Post response!");
}