Due to some major issues with caching in the UIWebView, I'm requesting an HTML page myself and loading it into the web view using the following method:
-(void)loadData:(NSData *)data MIMEType:(NSString *)MIMEType
textEncodingName:(NSString *)encodingName baseURL:(NSURL *)baseURL
Previously, I've been setting thebaseURL
to nil
since all resources were defined with absolute URLs. I found 1 relative link, and rather than try to guarantee that all resources in the future have absolute paths, I thought it would be better to specify base URL. When I try doing that, the web view loads the base URL instead of the 开发者_开发百科NSData.
There isn't much in Apple's documentation for base URL. What's the expected behavior here?
精彩评论