有没有办法捕获UIWebView中的链接点击.我想找出用户点击的地址,但实际上没有找到该页面.
这可能吗?
是的,您可以查看控制器可以实现的委托方法:
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType
参考:
http://developer.apple.com/iPhone/library/documentation/UIKit/Reference/UIWebViewDelegate_Protocol/Reference/Reference.html#//apple_ref/occ/intfm/UIWebViewDelegate/webView:shouldStartLoadWithRequest:navigationType :