New error in iOS 5: WebKit discarded an uncaught exception

后端 未结 2 1873
野性不改
野性不改 2021-02-06 09:09

I am trying to load a UIWebView with the Facebook OAuth authorization URL and I am using the following code. When my UIWebView loads with Facebook logi

2条回答
  •  轮回少年
    2021-02-06 09:26

    Are you using the Ray Wenderlich code? (FBFunLoginDialog).. I found that this fixes it:

    -(void)checkLoginRequired:(NSString *)urlString {
        NSLog(@"Url: %@",urlString);
        if ([urlString rangeOfString:@"login.php"].location != NSNotFound && [urlString rangeOfString:@"refid"].location == NSNotFound) {
                [_delegate displayRequired];
        } else if ([urlString rangeOfString:@"user_denied"].location != NSNotFound) {
             [_delegate closeTapped];
        }
    }
    

提交回复
热议问题