Protocol: UIWebViewDelegate

Overview

The UIWebViewDelegate protocol defines methods that a delegate of a UIWebView object can optionally implement to intervene when web content is loaded.Sent if a web view failed to load a frame.Sent before a web view begins loading a frame.Sent after a web view finishes loading a frame.Sent after a web view starts loading a frame.

Instance Method Summary (collapse)

Instance Method Details

- (Object) webView(webView, didFailLoadWithError:error)

Sent if a web view failed to load a frame.

Parameters:

  • webView (UIWebView)

    The web view that failed to load a frame.

  • error (NSError)

    The error that occurred during loading.

Returns:

- (Boolean) webView(webView, shouldStartLoadWithRequest:request, navigationType:navigationType)

Sent before a web view begins loading a frame.

Parameters:

  • webView (UIWebView)

    The web view that is about to load a new frame.

  • request (NSURLRequest)

    The content location.

  • navigationType (UIWebViewNavigationType)

    The type of user action that started the load request.

Returns:

  • (Boolean)

    YES if the web view should begin loading content; otherwise, NO .

- (Object) webViewDidFinishLoad(webView)

Sent after a web view finishes loading a frame.

Parameters:

  • webView (UIWebView)

    The web view has finished loading.

Returns:

- (Object) webViewDidStartLoad(webView)

Sent after a web view starts loading a frame.

Parameters:

  • webView (UIWebView)

    The web view that has begun loading a new frame.

Returns: