user2918057
user2918057

Reputation: 199

Open an UIView when click a Link on UIWebview

How can I open an UIView when click a Link on UIWebview?

I've a project iOS UIWeview, and I need open an UIView when click some link.

I tried use this on my ViewController UIWebview:

- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType {

    NSLog(@" In - shouldStartLoadWithRequest ");

    return YES; }

I did something wrong?

Thanks!

Solution:

on: myViewController.h

ViewController<UIWebViewDelegate>

Upvotes: 0

Views: 181

Answers (1)

Vladimir
Vladimir

Reputation: 531

Did you set the delegate for the webview?

Upvotes: 2

Related Questions