NSURL *baseURL = [NSURL URLWithString:@"https://graph.facebook.com/"]; AFHTTPClient *httpClient = [[AFHTTPClient alloc] initWithBaseURL:baseURL]; NSString *link = [NSString stringWithFormat:@"/%@/likes", @"OBJECT_ID"]; NSDictionary *params = @{@"access_token" : [[[FBSession activeSession] accessTokenData] accessToken]}; [httpClient postPath:link parameters:params success:^(AFHTTPRequestOperation *op, id result) { NSLog(@"result %@", result); } failure:^(AFHTTPRequestOperation *operation, NSError *error) { NSLog(@"error %@", error); }];That's it, don't hesitate to comment, to share your knowledge and to correct me.
Friday, April 5, 2013
Implement a (Like) action for any object on Facebook (except the pages) using AFNetworking.
Posted by Polaris on 7:41 PM
Subscribe to:
Post Comments (Atom)
nice blog
ReplyDeleteRPA Training in Bangalore
MEAN Stack Training in Bangalore
MERN StackTraining in Bangalore
Blue Prism Training in Bangalore
informatica Training in Bangalore
Azure DevOps training in Bangalore
Google Cloud Training in Bangalore
Android Training in Bangalore
Best Android Training Institute in Bangalore
steroid satın al
ReplyDeleteheets
BGSF
https://saglamproxy.com
ReplyDeletemetin2 proxy
proxy satın al
knight online proxy
mobil proxy satın al
ZNS0H