我正试图将我的IOS应用程序发布到facebook feed。以下是我在代码中包含的测试。
Facebook *facebook = [[Facebook alloc] initWithAppId:FB_APPID_REMOTE andDelegate:self];
// Create the parameters dictionary that will keep the data that will be posted.
NSMutableDictionary *fbParams = [NSMutableDictionary dictionaryWithObjectsAndKeys:
@"My test app", @"name",
@"http://www.google.com", @"link",
@"FBTestApp app for iPhone!", @"caption",
@"This is a description of my app", @"description",
@"Hello!\n\nThis is a test message\nfrom my test iPhone app!", @"message",
nil];
[facebook requestWithGraphPath:@"me/feed" andParams:fbParams andHttpMethod:@"POST" andDelegate:self];
但是,我没有看到帖子更新到我的Facebook Feed。我错过了什么吗?
答案 0 :(得分:0)
方法requestWithGraphPath
返回FBRequest
的对象。因此,您可以检查request.state
以确定请求的状态,并检查request.error
以了解问题究竟是什么。
答案 1 :(得分:0)
使用AppDelegate
将返回您从View
调用的同一页ViewController
。但是,由于您没有收到任何明显的错误日志或崩溃,我认为这是Facebook graph protocol
的一些问题。
将"me/feed"
替换为"feed"
,因为这对我来说很合适。