Xcode 7中的错误:App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.

这个错误是由于iOS发布的HTTPS造成的,凡是没有添加以下条目的都会报这个错误:
App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.

要改正很简单,在Info.plist文件中,添加一个条目:
App Transport Security Settings
然后再添加其子目录:
Allow Arbitrary Loads,并设置为YES.
看下图:


Xcode 7中的错误:App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file._第1张图片
屏幕快照 2016-09-28 上午12.02.32.png

Xcode 7中的错误:App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file._第2张图片
屏幕快照 2016-09-28 上午12.03.00.png

你可能感兴趣的:(Xcode 7中的错误:App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.)