【发布时间】:2011-12-08 02:36:58
【问题描述】:
FB.ui(
{
method: 'feed',
name: 'some text',
link: 'some text',
picture: 'aa.jpg',
caption: 'some text',
description: 'some text',
message: 'some text'
},
function(response) {
if (response && response.post_id) {
alert('Post was published.');
} else {
alert('Post was not published.');
}
});
}
该代码工作正常,现在我喜欢之后:
alert('Post was published.');
从 facebook 中退出,静默 怎么样?
在alert('post publish') 之后添加该代码没有做任何事情!
FB.ui(
{ method:'auth.logout', display:'hidden' },
function() { alert("you're logged out!"); }
);
我找到了:FB auth.logout is being raised after being logged in using the "server-side-workflow" (OAuth 2.0),但不确定我是否理解代码足以知道它按我的要求做!
【问题讨论】:
-
如果您不使用注销按钮,那么您需要将应用程序访问令牌附加到注销 url “php-sdk” 我认为它不适用于 javascript,除非您构建注销 url自己。
-
有趣的答案,但对我来说看起来像mumbojumbo...请给我一个例子,请提供一些代码!...我没那么聪明!