I am trying to parse a json string requested from an api located at: http://www.physics.leidenuniv.nl/json/news.php
However, i am having trouble parsing this json. I get
-(void)getWebServic{
NSURL *url = [NSURL URLWithString:@"----URL----"];
// 2
NSURLSessionDataTask *downloadTask = [[NSURLSession sharedSession]
dataTaskWithURL:url completionHandler:^(NSData *data, NSURLResponse *response, NSError *error)
{
NSDictionary *jsonObject=[NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingMutableLeaves error:nil];
[self loadDataFromDictionary:(NSArray*)jsonObject];
NSLog(@"data: %@",jsonObject);
}];
// 3
[downloadTask resume]; }