0
votes

I have an application, where I play videos. In previous version of iOS, I kept playing videos in Html5 player in a web view and disable the option to go to full screen so, iOS was not able to open the native player. From iOS 10, when video starts playing, the native player takes charge and opens the video in full screen so , I can not continue with my background work in Html.

I have added two lines in past to overcome the issue in Webview however that seems not to work in iOS 10, I tried compiling the code in iOS 9 but it's working.

    playerWebView.allowsInlineMediaPlayback = true
    playerWebView.mediaPlaybackRequiresUserAction = false
1

1 Answers

0
votes

Form iOS 10 the browser will recognise and honour the playsinline directive in your HTML markup.

<video playsinline>

Using this should allow your video to play inline.