0
我在做上传图片,但使用“脸谱”无法识别的网络代码看,所以它的框架,我需要在iOS中使用? 你有代码示例吗? 我发现这个代码:框架上传与标题图片至Facebook
- (IBAction)uploadPhoto:(id)sender {
NSString *path = @"http://www.facebook.com/images/devsite/iphone_connect_btn.jpg";
NSURL *url = [NSURL URLWithString:path];
NSData *data = [NSData dataWithContentsOfURL:url];
UIImage *img = [[UIImage alloc] initWithData:data];
NSMutableDictionary * params = [NSMutableDictionary dictionaryWithObjectsAndKeys:img, @"picture", @"my photo's caption text here.", @"message", nil];
[facebook requestWithMethodName: @"photos.upload" andParams:params andHttpMethod:@"POST" andDelegate:self];
[img release];
}