使用 UIWebview 和基本身份验证(身份验证有效)但是我没有下载图像?谁能指出我正确的方向?
我正在连接这个:
connection = [[NSURLConnection alloc] initWithRequest:sourceUrl
delegate:self
startImmediately:YES];
-(void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data{
NSLog(@"%s", __FUNCTION__);
[webData appendData:data];
}
-(void)connectionDidFinishLoading:(NSURLConnection *)connection{
NSLog(@"%s", __FUNCTION__);
[_webView loadData:webData
MIMEType: @"text/html"
textEncodingName: @"UTF-8"
baseURL:nil];
我的网页很好,但有几张图片没有加载。