现在我正在开发一些包含引号的应用程序,我希望能够在我的Facebook墙上分享任何引用
我正在使用sdk 3,我可以登录,但我无法在没有对话的情况下发布在墙上?
这是我的帖子功能: -
private void PublishToFeedInBackground() {
final Bundle _postParameter = new Bundle();
_postParameter.putString("name", "ahmed");
_postParameter.putString("link", "eew");
_postParameter.putString("picture", "ew");
_postParameter.putString("caption", "we");
_postParameter.putString("message", "efwefwefwe");
_postParameter.putString("description", "few");
final List<String> PERMISSIONS = Arrays.asList("publish_stream");
if (Session.getActiveSession() != null) {
NewPermissionsRequest reauthRequest = new Session.NewPermissionsRequest(this, PERMISSIONS);
Session.getActiveSession().requestNewPublishPermissions(reauthRequest);
}
this.runOnUiThread(new Runnable() {
@Override
public void run() {
Request request = new Request(Session.getActiveSession(), "me/feed", _postParameter, HttpMethod.POST);
RequestAsyncTask task = new RequestAsyncTask(request);
task.execute();
}
});
}
答案 0 :(得分:0)
试试这个 -
[FBRequestConnection startWithGraphPath:@"feed" parameters:fbArguments HTTPMethod:@"POST" completionHandler:^(FBRequestConnection *connection, id result, NSError *error) {}];