Iphone 在IOS sdk中集成Twitter
在我的应用程序中,我想从推特上获取以下/关注者朋友的列表 现在,我只能获取追随者的姓名和id,但无法获取以下信息。 我的代码如下:Iphone 在IOS sdk中集成Twitter,iphone,ios,objective-c,xcode,twitter,Iphone,Ios,Objective C,Xcode,Twitter,在我的应用程序中,我想从推特上获取以下/关注者朋友的列表 现在,我只能获取追随者的姓名和id,但无法获取以下信息。 我的代码如下: -(void) getTwitterFriendsIDListForThisAccount{ NSURL *url = [NSURL URLWithString:@"http://api.twitter.com/1/followers/ids.json"]; NSDictionary *p = [NSDictionary dictionaryWit
-(void) getTwitterFriendsIDListForThisAccount{
NSURL *url = [NSURL URLWithString:@"http://api.twitter.com/1/followers/ids.json"];
NSDictionary *p = [NSDictionary dictionaryWithObjectsAndKeys:myAccount.username, @"screen_name", nil];
TWRequest *twitterRequest = [[TWRequest alloc] initWithURL:url parameters:p requestMethod:TWRequestMethodGET];
[twitterRequest setAccount:myAccount];
[twitterRequest performRequestWithHandler:^(NSData *responseData, NSHTTPURLResponse *urlResposnse, NSError *error)
{
if (error) {
}
NSError *jsonError = nil;
// Convert the response into a dictionary
NSDictionary *twitterFriends = [NSJSONSerialization JSONObjectWithData:responseData options:NSJSONWritingPrettyPrinted error:&jsonError];
NSArray *IDlist = [twitterFriends objectForKey:@"ids"];
NSLog(@"response value is: %@", IDlist);
}
如何获取以下列表ID???以及电子邮件ID(如果可能的话)
有时会显示迁移错误。如何从1.0迁移到1.1?
谢谢,这是最好的解决方案之一:只需下载Sharekit并按照步骤操作即可 共享套件 查看SHKTwitter.h和SHKTwitter.m文件,您可以得到它 很容易