【问题标题】:Unable to set initialtext in ios9 in native facebook share dialog无法在原生 facebook 共享对话框中的 ios9 中设置初始文本
【发布时间】:2015-12-17 20:25:08
【问题描述】:

我正在尝试在 iOS 9 中将初始文本设置为 SLComposeViewController,但它在对话框中显示为空白。

这是我的代码。

 SLComposeViewController *composeController = [SLComposeViewController composeViewControllerForServiceType:SLServiceTypeTwitter];

                 NSString *initialText = @"Tesing text issue.";

                 if (initialText != Nil)
                 {
                     [composeController setInitialText:initialText];
                 }
 dispatch_async(dispatch_get_main_queue(), ^
                                {
                                    //show progress hud here
                                    [self presentViewController:composeController animated:YES completion:nil];
                            });

我也在另一个共享应用程序中检查过这个,他们也有同样的问题。任何人都可以在这里有任何解决方法吗?

【问题讨论】:

    标签: ios iphone facebook ios9


    【解决方案1】:

    Facebook 已弃用在分享时以编程方式设置初始文本的 api。以下是参考资料:

    希望这会有所帮助。

    【讨论】:

      【解决方案2】:

      您可以使用图形 API 和自定义共享对话设置初始文本。 https://developers.facebook.com/docs/sharing/opengraph/ios#custom

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2017-07-16
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2014-04-07
        • 2012-12-03
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多