我有 UIWebView 我想在其中加载图像但它没有显示图像我正在使用以下代码
pdfView.hidden=NO;
webView.hidden=NO;
pdfView.backgroundColor=[UIColor clearColor];
doneButton = [[UIBarButtonItem alloc]initWithTitle:@" Done " style:UIBarButtonItemStyleBordered target:self action:@selector(doneButtonClick)];
self.navigationItem.leftBarButtonItem =doneButton;
webView.backgroundColor=[UIColor clearColor];
NSLog(@"File Name is %@",fileName);
NSString *path = [[NSBundle mainBundle] pathForResource:fileName ofType:@"png"];
NSURL *url = [NSURL fileURLWithPath:fileName];
NSURLRequest *request = [NSURLRequest requestWithURL:url];
[webView setScalesPageToFit:YES];
[webView loadRequest:request];
有什么方法可以加载这个来自 webView 中服务器的文件名中的图像谢谢