I am wondering if this is actually possible,because I am running out of solutions for my problem.The bit.ly short links are just ruining my day lol. The code below is what I am trying to pull off, but this doesn't work with bit.ly links. And it is always detecting bit.ly links first then google redirected links next.
-(BOOL) webView:(UIWebView *)inWeb shouldStartLoadWithRequest:(NSURLRequest *)inRequest navigationType:(UIWebViewNavigationType)inType {
if ( inType == UIWebViewNavigationTypeLinkClicked ) {
if ([[inRequest.URL absoluteString] rangeOfString:@"google"].location==NSNotFound){
[[UIApplication sharedApplication] openURL:[inRequest URL]];
return NO;
}
}
return YES;
}