我是从我的应用程序向fb朋友发送请求但是我没有收到我发送请求的fb用户墙上的任何通知?
我正在使用FB SDK 3.2(我希望它是最新的)
以下是我用来发送请求的代码
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
friendList, @"to",
nil];
[FBWebDialogs presentRequestsDialogModallyWithSession:nil
message:[NSString stringWithFormat:@"I just smashed %d friends! Can you beat it?", 15]
title:@"Total Smashed Score"
parameters:params
handler:^(FBWebDialogResult result, NSURL *resultURL, NSError *error) {
if (error) {
// Case A: Error launching the dialog or sending request.
NSLog(@"Error sending request.");
} else {
if (result == FBWebDialogResultDialogNotCompleted) {
// Case B: User clicked the "x" icon
NSLog(@"User canceled request.");
} else {
NSLog(@"Request Sent.");
}
}
}
];
正确显示请求对话框,当我单击发送按钮时,邀请会被发送但未显示在用户墙上。任何类型的帮助将不胜感激。
问候。
答案 0 :(得分:1)
邀请永远不会显示在用户的墙/时间轴上。只有用户可以私下查看。该信息将显示在Requests page上或作为通知给用户。
答案 1 :(得分:0)
这是我的解决方案
//friendlist = NSString of fb id's
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
friendList, @"to",
nil];
[FBWebDialogs presentRequestsDialogModallyWithSession:nil
message:[NSString stringWithFormat:@"message!"]
title:@"title"
parameters:params
handler:^(FBWebDialogResult result, NSURL *resultURL, NSError *error) {
if (error) {
// Case A: Error launching the dialog or sending request.
NSLog(@"Error sending request.");
} else {
if (result == FBWebDialogResultDialogNotCompleted) {
// Case B: User clicked the "x" icon
NSLog(@"User canceled request.");
} else {
NSDictionary *urlParams = [self parseURLParams:[resultURL query]];
if (![urlParams valueForKey:@"request"]) {
// User clicked the Cancel button
NSLog(@"User clicked cancel button.");
} else {
nslog("succesfully sent invites");
}
}
}
}
];