简体   繁体   English

在多个朋友的facebook墙上发帖

[英]post on multiple friends facebook wall

I make application with only one facebook wall post. 我只用一个facebook墙贴提出申请。 It works good for me using FBConnect. 使用FBConnect对我很好。 but now i want wall post to multiple friends at a time on one button click. 但是现在我想一次单击将墙贴一次发给多个朋友。 Is it possible for post on multiple friends wall? 是否可以在多个朋友的墙上发帖? If it is possible then suggest me. 如果可能的话,建议我。

My Code : 我的代码:

NSMutableDictionary *params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
                                   [NSString stringWithFormat:@"%@",[[arrData objectAtIndex:i] objectForKey:@"id"]], @"to",
                                   @"post on facebook", @"name",
                                   @"facebook wall post", @"description",
                                   @"http://m.facebook.com/apps/myapp", @"link",
                                   nil];

    AppDelegate *delegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
    [[delegate facebook] dialog:@"feed"
                      andParams:params
                    andDelegate:self];

Please reply me. 请回复我。

Thanks in advance for help. 在此先感谢您的帮助。

If you are using the feed dialog then you have no choice but to open a dialog per friend. 如果使用的是供稿对话框,则别无选择,只能为每个朋友打开一个对话框。

What you can do though is request the publish_stream parameter which lets you publish as the logged in user on his or his friends walls. 不过,您可以执行的操作是请求publish_stream参数,该参数可让您以登录用户的身份发布在他或他的朋友墙上。
After you get that permission you simply send a request to fb and it gets published, without the use of a dialog, which let's you send as many requests as you like. 获得该许可后,您只需将请求发送到fb即可发布,而无需使用对话框,这样您就可以根据需要发送任意数量的请求。

On the ios sdk it's done with Requests . 在ios SDK中,它是通过Requests完成的。

If you already know how to post users wall then you can do this task using following approach, Or see this link for help 如果您已经知道如何在用户墙上发布内容,则可以使用以下方法执行此任务,或者查看链接以获取帮助

  1. Get Face book fiends id for all your friends. 获取您所有朋友的Face book fiends id。
  2. Save in array. 保存在数组中。
  3. Iterate loop array's length and post one by one on friends wall. 迭代循环数组的长度,并一一贴在朋友墙上。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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