Monday, May 9, 2016

Load a UIImage from a URL


Make sure enable this settings from iOS 9:

App Transport Security Settings in Info.plist to ensure loading image from URL so that it will allow download image and set it.






And write this code:
NSURL *url = [[NSURL alloc]initWithString:@"http://iosdevelopertips.com/images/logo-iphone-dev-tips.png"];
NSData *data =[NSData dataWithContentsOfURL:url];
quickViewImage.image = [UIImage imageWithData:data];

1 comments :



  1. It is really very excellent,i find all articles was amazing.awesome way to get exert tips from everyone,
    not only i like that post all peoples like that post,because of all given information was wonderful and it's very helpful for me.
    Dotnet training in Chennai

    ReplyDelete

 

Copyright @ 2014 Tech Tutorial .