Cannot load HTTP links in UIWebView in iOS 9

Skywalker picture Skywalker · Sep 21, 2015 · Viewed 11.2k times · Source

I am trying to load HTTP links within UIWebView. The links are from my website so they are reliable. I have searched the internet and found the solution here: How can I add NSAppTransportSecurity to my info.plist file?

After following that solution my info.plist looks like this.:

enter image description here

Even after making the changes I cannot load HTTP links within UIWebView. I get the following error:

App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure

Is there something I am doing wrong?

UPDATE:

After making the changes suggested by Ramshad in comments it still does not work. See image below:

enter image description here

Answer

Grigori Jlavyan picture Grigori Jlavyan · Oct 1, 2015

It should be done like this, you need to add in your Plist the following records Apple Documentation

NSAppTransportSecurity <- Type Dictionary

NSAllowsArbitraryLoads <- Type Boolean Value YES

enter image description here