How do I load an HTTP URL with App Transport Security enabled in iOS 9? [duplicate]

This question already has answers here: Transport security has blocked a cleartext HTTP (29 answers) Closed 6 years ago. So, the new beta SDK of iOS released last night has “App Transport Security” which encourages developers to use https instead of http. In principle, this is a great idea, and I already use https in … Read more

Loading/Downloading image from URL on Swift

I’d like to load an image from a URL in my application, so I first tried with Objective-C and it worked, however, with Swift, I’ve a compilation error: ‘imageWithData’ is unavailable: use object construction ‘UIImage(data:)’ My function: @IBOutlet var imageView : UIImageView override func viewDidLoad() { super.viewDidLoad() var url:NSURL = NSURL.URLWithString(“http://myURL/ios8.png”) var data:NSData = NSData.dataWithContentsOfURL(url, … Read more