iOS 8.3 and Later, Facebook Share Text Not Inserted

iOS 8.3 and later, Facebook share text not inserted

Looks like Facebook doesn't want the app to pre-propagate the share dialog with text anymore :(

It doesn't have to do anything with the iOS version, but with the build in Facebook App (as the share processes is somehow interlinked with the FB app)

It's stupid and on Android you couldn't do it either (it was disabled longer ago) i hope Facebook reconsiders this as it will lead to fewer shares and some might be willing to drop the share option

Note: if the user doesn't have the FB app installed (he removed it), than the text is added to the status, but i guess that only a small amount of users, but maybe a good reason to still supply text to the share items

Facebook text share not working with UIActivityViewController

This won't work if you have the newest Facebook app installed - the text always blank and sometimes URL doesn't show in facebook version 31.0 . This share feature only works older app means version less than 28..

iOS 8.3 Facebook error Not logged In

Yes, this is a bug that went out in Version 29 of the Facebook application. We (Facebook) are working on a fix and hope that it will ship soon.

SLServiceTypeFacebook setInitialText is not working

It seems to be a problem having installed the latest Facebook app update (v29). Removing it "fixes" the problem.

https://developers.facebook.com/bugs/1632385646995079/
https://developers.facebook.com/bugs/962985360399542/

Update (Jun. 3, 2015)

Well. It seems that the new Facebook policy says that prefilling a message through setInitialText: is a prefill violation.

https://developers.facebook.com/docs/apps/review/prefill

So I guess the only way to share content from now on is the FBSDKShareDialog

https://developers.facebook.com/docs/sharing/ios

iOS: How to share text and image on social networks?

It seems that a recent update to the Facebook application has replaced the in-built Facebook share activity with one that ignores status text - If you remove the Facebook app from your device the text will be displayed using the code you have. If you have the Facebook app installed you get images, URLs but not the text

Facebook's policies don't allow you to pre-populate status messages and require all content to be user generated - while I understand the intention behind this, I personally think it is kind of stupid in many cases - For example in my game I want to pre-populate the user's score, but now I can't, so the user is presented with an empty dialog box. I will probably simply remove the Facebook sharing option as no-one will ever use it now.

This response from Facebook confirms that the behaviour is by design

Facebook is not shown in UIActivityViewController but twitter does

I first saw this when Facebook updated their app on April 24th. Plain text sharing to Facebook isn't working as long as the Facebook app is installed. After you delete it, it's available again.

If you try to share a URL or an image together with the plain text, you will see Facebook as an option but the text field will be blank. The image or URL will attach without a problem.

I posted a sample project that reproduces this problem on github:

https://github.com/djr/UIActivityViewController-Facebook

This is not an answer, but it's pretty clear that the problem is caused by the Facebook app.

EDIT:

It's not ideal, but I created a workaround. Don't forget that you will need to attach an image or a URL for this to work.

  1. Detect if the user has the Facebook app installed. If they do, then give them some type of informational message.

    BOOL facebookIsInstalled = [[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"fb://"]];
    BOOL isUserLoggedInWithFacebook = [SLComposeViewController isAvailableForServiceType:SLServiceTypeFacebook];

    if(isUserLoggedInWithFacebook && facebookIsInstalled)
    {
    // Explain that they have to copy and paste in order to share on Facebook
    }
  2. Create a subclass of UIActivityItemProvider and override

    - (id)activityViewController:(UIActivityViewController *)activityViewController itemForActivityType:(NSString *)activityType
    {
    NSString *stringToShare = @"string to share";

    if([activityType isEqualToString:UIActivityTypePostToFacebook] ||
    [activityType isEqualToString:@"com.facebook.Facebook.ShareExtension"] ||
    [activityType.lowercaseString rangeOfString:@"facebook"].length)
    // Because who knows when they are going to change the activityType string?
    {
    // Automatically copy the text for them
    [[UIPasteboard generalPasteboard] setString:stringToShare];
    }

    return stringToShare;
    }
  3. Tell the user that they have to paste into the Facebook text field in order to share.

  4. Blame it on Facebook.



Related Topics



Leave a reply



Submit