Skip to content

Instantly share code, notes, and snippets.

@tarappo tarappo/gist:4951343
Created Feb 14, 2013

What would you like to do?
特定のURLの時はブラウザで表示。 ※事前にself.webView.delegate = self;をしておく。
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType {
if (navigationType == UIWebViewNavigationTypeLinkClicked) {
NSString *checkURL = [request.URL absoluteString];
NSRange linkMatch = [checkURL rangeOfString:@""];
if (linkMatch.location != NSNotFound) {
[[UIApplication sharedApplication] openURL:request.URL];
return NO;
return YES;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.