How to prevent the HTML5 video tag from automatically full screen in iPhone

一个新手
Release: 2017-10-09 10:23:46
Original
2670 people have browsed it

Problem: When opening a video in an HTML5 page on an iPhone, the system player will be called by default and the video resource will be played in full screen.

Solution: 1. First, add webkit-playsinline=true in the video tag of the html5 page;

<video id="player" webkit-playsinline></video>
Copy after login
2. If you are using Phonegap or Cordova; you can configure it in the config.xml configuration file:

webview.allowInlinesMediaPlayback = YES;
Copy after login
Then in the video tag Add webkit-playsinline attribute.

The above is the detailed content of How to prevent the HTML5 video tag from automatically full screen in iPhone. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template