你好,歡迎來到IOS教程網

 Ios教程網 >> IOS編程開發 >> IOS開發綜合 >> iphone中的Foursquare集成的實現

iphone中的Foursquare集成的實現

編輯:IOS開發綜合
原問題描述: 需要實現iphone中關於Foursquare集成,但是不知道從何入手,請幫忙給一些建議和指點。謝謝 解決方案: 這裡是foursquare api 鏈接 Foursquare integration 示例鏈接 更多代碼:Foursquare integration [plain]  - (void)viewDidLoad   {       [super viewDidLoad];          self.title = @"Foursquare";       //check the authentication       if ([Foursquare2 isNeedToAuthorize]) {          //If needed show the webview            webView = [[UIWebView alloc]initWithFrame:CGRectMake(0, 0, 320, 480)];           NSString *url = [NSString stringWithFormat:@"https://foursquare.com/oauth2/authenticate?display=touch&client_id=%@&response_type=code&redirect_uri=%@",OAUTH_KEY,REDIRECT_URL];           NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:url]];           [webView loadRequest:request];           [webView setDelegate:self];           [self.view addSubview:webView];           [webView release];           mTableView.hidden = YES;       }else{           //Show your view           mTableView.hidden = NO;           [Foursquare2 searchVenuesNearByLatitude:@"40.763" longitude:@"-73.990" accuracyLL:nil altitude:nil accuracyAlt:nil query:@"" limit:@"15" intent:@"" callback:^(BOOL success, id result){               if (success) {                      tableData = [[FoursquareParser parseSearchVenuesResultsDictionary:(NSDictionary*)result] retain];                   [mTableView reloadData];                  }           }];          }   }      
  1. 上一頁:
  2. 下一頁:
蘋果刷機越獄教程| IOS教程問題解答| IOS技巧綜合| IOS7技巧| IOS8教程
Copyright © Ios教程網 All Rights Reserved