错误9802是根据苹果的docs“致命警报”。我已经看过谷歌和SO,并没有发现任何引用9802修复了这个问题。我可以将我的代码更改为“apple.com”,然后我得到该页面,但使用我自己的URL,我得到上述错误。我试过了我能想到的所有东西,但没有任何效果。有时间寻求帮助! :dHTTP加载失败,我尝试了所有的建议,但没有任何工作
使用
/usr/bin/nscurl --ats-diagnostics https://pragerphoneapps.com
的结果是所有测试失败(结果上传here)
这是我的应用程序的.plist文件中的图像(仅适用于相关部分)
并且这是目标信息的图像:
这是我的代码:
- (IBAction)showHTMLHelp:(UIButton *)sender {
// make the popover
UIViewController* popoverContent = [UIViewController new];
UIView* popoverView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 450, 500)];
popoverView.backgroundColor = [UIColor colorWithWhite:(CGFloat)1.0 alpha:(CGFloat)1.0]; // frame color?
popoverContent.view = popoverView;
//resize the popover view shown in the current view to the view's size
popoverContent.preferredContentSize = CGSizeMake(450, 500);
NSString *urlAddress = @"https://pragerphoneapps.com"; // @"https://www.pragerphoneapps.com/bookstore-inventory-manager/upload-help/";
NSURL *url = [NSURL URLWithString:urlAddress];
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
// add the UIWebView for RichText
UIWebView *webView = [[UIWebView alloc] initWithFrame: popoverView.frame];
webView.backgroundColor = [UIColor whiteColor]; // change background color here
// add the webView to the popover
[webView loadRequest:requestObj];
[popoverView addSubview:webView];
// if previous popoverController is still visible... dismiss it
if ([popoverController isPopoverVisible]) {
[popoverController dismissPopoverAnimated:YES];
}
//create a popover controller
popoverController = [[UIPopoverController alloc] initWithContentViewController:popoverContent];
[popoverController presentPopoverFromRect:((UIButton *)oShowHelp).frame inView:self.view
permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
}
它可以与http域一起工作吗?如果是这样,那么问题不可能是你的代码。检查一下; http://stackoverflow.com/questions/38719075/ios-kcfstreamerrordomainssl-9813 –
没有...不适用于http或https;出现此错误:由于App Security Transport Security不安全,因此App Transport Security已阻止明文HTTP(http://)资源加载。临时例外可以通过您的应用程序的Info.plist文件进行配置。 – SpokaneDude
您的目标网站遭到入侵或证书不正确。它甚至不会在Chrome中打开。 –