Swift学习笔记(二)Ios9下访问http://

前端之家收集整理的这篇文章主要介绍了Swift学习笔记(二)Ios9下访问http://前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

如果你出现

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
文本编辑,或xcode open as source code
在节点内加入

<key>NSAppTransportSecurity</key>
<dict>
     <key>NSAllowsArbitraryLoads</key>
     <true/>
</dict>
原文链接:https://www.f2er.com/swift/325695.html

猜你在找的Swift相关文章