social-framework

Share videos on Twitter via iOS App

百般思念 提交于 2019-12-20 09:45:50
问题 Is it possible to share a video using SLRequest ? I'm able to share Images using the same SLRequest *postRequest = [SLRequest requestForServiceType:SLServiceTypeTwitter requestMethod:SLRequestMethodPOST URL:requestURL parameters:message]; if (isImage) { NSData *data = UIImagePNGRepresentation(imgSelected); [postRequest addMultipartData:data withName:@"media" type:@"image/png" filename:@"TestImage.png"]; } postRequest.account = account; [postRequest performRequestWithHandler:^(NSData

SLComposeViewController with screenshot but not image attachment

二次信任 提交于 2019-12-19 19:46:31
问题 I notice that Mobile Safari's Twitter and Facebook share adds a screenshot of the current page without actually sharing it, eg: Im trying to duplicate this via SLComposeViewController, however calling the addImage: actually adds the UIImage to the tweet/facebook album (as expected). Is there a way to just display the screenshot of the page without adding the image ? Edit: Looks like SLComposeViewController conforms to UIAppearanceContainer however the UI_APPEARANCE_SELECTOR is not documented.

Post to Friends wall on Facebook failed with Social Framework in iOS 6

泄露秘密 提交于 2019-12-18 17:13:12
问题 I am trying to POST a invitation to iOS app on my facebook friends wall using Social framework in iOS 6+. But it gives me following error error = { code = 200; message = "(#200) Feed story publishing to other users is disabled for this application"; type = OAuthException; }; I know this is due to Facebook disable this functionality as mentioned on Facebook blog & this stackoverflow question On stackoverlow's page , it is written that use feed dialog. But I can't see any option to use feed

TWRequest is deprecated in iOS 6.0 - what can I use instead?

眉间皱痕 提交于 2019-12-18 11:03:38
问题 I'm developing a Twitter Feed View for an iOS App. I found TWRequest and it works exactly like that which i was looking for. But: i get an Notice: "TWRequest is deprecated: first deprecated in iOS 6.0". What should I use instead? 回答1: On iOS 6 you should use the Social.framework . This has a class named SLRequest . You use it almost in the same way as the deprecated TWRequest , but you need to specify that it's a twitter request as opposed to a facebook request. The entire Twitter.framework

ACAccountCredential returns null for oauthToken

别等时光非礼了梦想. 提交于 2019-12-12 11:44:07
问题 I am getting access to user's facebook via: [accStore requestAccessToAccountsWithType:fbAccountType options:options completion:^(BOOL granted, NSError *error) { if (granted) { // If access granted, then get the Facebook account info NSArray *accounts = [accStore accountsWithAccountType:fbAccountType]; ACAccount *acc = [accounts lastObject]; // Get the access token, could be used in other scenarios ACAccountCredential *fbCredential = [acc credential]; NSString *accessToken = [fbCredential

iOS Facebook Framework login process

六眼飞鱼酱① 提交于 2019-12-12 04:18:50
问题 I am developing an iOS app in which I am providing functionality to login via Facebook. For this I am using the Facebook framework. I have gone through developers.facebook.com and implemented login functionality as described there. FB login is working properly. FB login functionality works like this: FB Framework will try to find FB App, if it is present then it will authenticate using FB app credentials. If FB app is not present then it will try to authenticate using the iPhone device

Facebook iOS6 integration adds image to album and not separate posts

五迷三道 提交于 2019-12-11 23:16:12
问题 I am trying to post to Facebook from my iOS app using the Social Framework. Using the SLComposeViewController, I have successfully added text and image to a Facebook post SLComposeViewController *postVC = [SLComposeViewController composeViewControllerForServiceType:SLServiceTypeFacebook]; [postVC setInitialText:messageText]; [postVC addImage:[UIImage imageNamed:@"share-this.png"]]; [self presentViewController:composeVC animated:YES completion:nil]; Now, the user of my app can post multiple

SLComposeViewController get the user that made the tweet and the message tweeted

与世无争的帅哥 提交于 2019-12-11 03:48:11
问题 I really want to use the iOS social framework and SLComposeViewController to tweet from my app but I need the twitter handle of the user tweeting and the tweet text on the completion (without me fetching latest tweets from all of users twitter accounts and detecting which one he used). Can I achieve this? If not, is there a good alternative for a textView with twitter handle autocomplete, character counter and twitter account selection? 来源: https://stackoverflow.com/questions/24143286

Fetching basic information (id, first_name) from Facebook by using Social Framework - source code and screenshots attached

梦想与她 提交于 2019-12-09 21:53:51
问题 For what would be a word game later I am trying to fetch very basic information about a player by using Social framework: id first_name gender location (i.e. nothing sensitive like email and I don't use Facebook iOS SDK). So in Xcode 5.0.2 I create a blank single view app for iPhone and add Social.framework to the Build phases tab. Then I add the following code to the ViewController.m: #import "ViewController.h" #import <Social/Social.h> #import <Accounts/Accounts.h> #define FB_APP_ID @

Twitter SLRequest performRequestWithHandler - Could not prepare the URL request

佐手、 提交于 2019-12-08 08:35:07
问题 I am trying to implement "Follow Us On Twitter" in my iOS app. Here is my code. But it give error "Could not prepare the URL request". Please help! ACAccountStore *accountStore = [[ACAccountStore alloc] init]; ACAccountType *accountType = [accountStore accountTypeWithAccountTypeIdentifier:ACAccountTypeIdentifierTwitter]; [accountStore requestAccessToAccountsWithType:accountType options:NULL completion:^(BOOL granted, NSError *error) { if (granted) { NSMutableDictionary *tempDict = [