简体   繁体   中英

Facebook Invitation API

I need to invite my friend from my ios native Application. I read documentation and used following code. I view popup, select my friend and send invite. Callback method says "Request Sent." but my friend don't receive nothing invite. Why?

[FBWebDialogs presentRequestsDialogModallyWithSession:nil
                                              message:[NSString stringWithFormat:@"I just smashed %d friends! Can you beat it?", 2]
                                                title:nil
                                           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.");
                                                      }
                                                  }}];

Can you help me please?

Thanks

When users are invited they receive "app requests" which appear under app requests Facebook page, rather than under the "globe" as you may expect. Have whoever is testing the code go check under "app requests" in the "app center." (For me the app center appears on the left side of my facebook home page.)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM