I am facing the Problem when I have updated my Xcode to 7.0 or iOS 9.0. Somehow it started giving me the Titled error
\"The resource could not be load
For iOS 10.x and Swift 3.x [below versions are also supported] just add the following lines in 'info.plist'
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
Make sure you change the right info.plist file.
This is the second time I waste time on this issue, because I didn't notice that I'm changing info.plist under MyProjectNameUITests.
Be aware, using NSAllowsArbitraryLoads = true
in the project's info.plist
allows all connection to any server to be insecure. If you want to make sure only a specific domain is accessible through an insecure connection, try this:
Or, as source code:
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>domain.com</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
<key>NSIncludesSubdomains</key>
<true/>
</dict>
</dict>
</dict>
Clean & Build project after editing.