Xcode 7 支持http请求info.plist设置
2015-10-26 11:25
537 查看
由于iOS9改用更安全的https,为了能够在iOS9中正常使用http发送网络请求,请在"Info.plist"中进行如下配置,否则影响SDK的使用。
1.找到项目中的 Info.plist 文件,右击,选择 open as ------>source code.
2.在打开的文件中光标定位倒数第二行。将下放的内容复制进去。
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
或者:
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
3.command +S 保存。
4.OK。
1.找到项目中的 Info.plist 文件,右击,选择 open as ------>source code.
2.在打开的文件中光标定位倒数第二行。将下放的内容复制进去。
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
或者:
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
3.command +S 保存。
4.OK。
相关文章推荐
- Webservice -- HttpCilent 访问Webservice 请求
- Xcode 7 支持http请求info.plist设置
- Xcode7 App Transport Security has blocked a cleartext HTTP (http://) resource load
- 常见的HTTPS攻击方法
- HttpClient和HttpURLConnection的区别
- IOS 设置启动图标 和 启动图片(转载自 http://justsee.iteye.com/blog/2123545)
- http请求服务
- 联想Y450按下Fn+F5不能弹出对话框开启无线网络
- javax.servlet.http.HttpServletRequest;
- 10月“.网络”域名总量:13家中国域名商多数量减
- http://www.reg007.com/
- Tcpdump常用方式小结
- javaweb学习总结(四)——Http协议
- 服务器设计-处理并发请求
- linux connect网络连接检测
- iOS--判断当前是否有网络
- ios 网络字节顺序的转换HTOS
- JAVA 获取http返回XML的数据
- 浏览器HTTP缓存原理分析
- Win7电脑开启局域网连接和共享过程中出现的"您可能没有权限使用网络资源"的解决办法