我试图在我的imageView中使用imageView上传图像。但出于某些原因,如果图像具有https://协议URL,则imageView加载良好,但如果图像具有http://协议,则不会加载抛出错误。这是一段代码,
[_imageView loadImageURL:[NSURL URLWithString:_news.imageURL] withCompleteBlock:^(UIImage *image) {
[_indicator stopAnimating];
[_indicator removeFromSuperview];
} withErrorBlock:^(NSError *error) {
NSLog(@"Could not uplad the picture");
[_indicator stopAnimating];
[_indicator removeFromSuperview];
}];//这里_imageView是RemoteImageView的实例。//此映像将加载

//但下面的图像将不会加载

谢谢
发布于 2015-10-29 14:47:30
这是,iOS 9中的新版本。如果需要,请参阅关于NSAppTransportSecurity的详细信息。建议的解决方案是将所有通信量移动到HTTPS。
https://stackoverflow.com/questions/33417185
复制相似问题