I'd like to use the FBDialog
from the Facebook SDK, but it seems like it only takes an URL for posting images. Is there any way to upload an UIImage
to Facebook using the FBDialog
without uploading the image to another server before posting?
I'm currently using this to post an UIImage
on facebook:
NSMutableDictionary *params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
@"A caption", @"caption",
nil];
[_facebook requestWithMethodName:@"photos.upload" andParams:params andHttpMethod:@"POST" andDelegate:nil];
It works great, but I need the FBDialog
. Is there any way to do same thing with the FBDialog
?
Any help is appreciated.
No, to post a UIImage
you cannot directly attach it. Here are two methods:
For more in-depth tutorial look at this link:
Official Facebook iOS Tutorial
This is a similar question with a great answer that provides step by step tutorial