Video tag not working on iPhone Safari or Chrome
In this tutorial, we will learn Video tags do not work on iPhone Safari or Chrome. Video tag works great on desktop browsers, Android Chrome, and even my iPad mini in Safari but iPhone Safari or Chrome not working. When I’m run video tag proper work on the google browser but iPhone (Safari or Chrome) not working, but today I found this solution. Today I’m solving video tag not playing on my iPhone browsers (Safari and Chrome) and certain pads.
I’ve tried adding the controls parameter back, video source within the video tag and removing the additional source tags, and compressing the heck out of my video but not working. and finally, I did include playsinline attribute in the video.
Old Code:
<video class="header-background" width="600" height="440" loop autoplay muted controls="true">
<source src="uploads/video.mp4" type="video/mp4" type="video/mp4"/>
</video>
New Code:
<video class="header-background" width="600" height="440" loop autoplay muted controls="true" playsinline>
<source src="uploads/video.mp4" type="video/mp4" type="video/mp4"/>
</video>