iOS WebView Guide


1.0 | Embedding the player in a WKWebView

To embed the player in a WKWebView in iOS, visit: https://developer.apple.com/reference/webkit/wkwebview

2.0 | Embedding the player in a UIWebView

To embed the player in a UIWebView in iOS, visit: https://developer.apple.com/reference/uikit/uiwebview

To enable inline playback on an iPhone, be sure to set

webView.allowsInlineMediaPlayback = YES;

To use autoplay use the following:

webView.mediaPlaybackRequiresUserAction = NO;

Place a Javascript embed code on a web page. The following script tag is an example embed code. Use the Online Video Platform to generate an embed code for your video content.

Make sure the selected playout has the setting “Force inView actions” enabled (read more about In- & Out View playout settings).

 

Load the web page in the webview.

NSURL *url = [[NSURL alloc] initWithString:@"http://yourcompany.com/demoWebPage"];
NSURLRequest *request = [[NSURLRequest alloc] initWithURL:url];
[self.webView loadRequest:request];

Was this article helpful?

Contact Support
Can't find the answer you're looking for?
Contact Support