What's wrong with this code
Console:
The link is http://www.apple.com
The string is http://www.apple.com
The NSURL is (null)
Code:
NSLog(@"The link is %@", [selectedContent objectForKey:@"link"]);
NSString *string = [[NSString alloc] initWithString:[selectedContent objectForKey:@"link"]];
NSLog(@"The string is %@", string);
NSURL *myURL = [[NSURL alloc] initWithString:string];
NSLog(@"The NSURL is %@", myURL);
NSURLRequest *myRequest = [[NSURLRequest alloc] initWithURL:myURL];
Console:
The link is http://www.apple.com
The string is http://www.apple.com
The NSURL is (null)