iFrame video not playing on iPhone (Safari)

Viewed 4325

I have a video page on my website which is linked to my google drive via the following code:

I am using google drive instead of YouTube, due to copyright issues with music.

The video links work fine on desktop (even though I don't like the idea of clicking twice on file). It used to work on mobile but doesn't now. Is there a way around this to work on mobile please?

Code:

<iframe style="align src="https://drive.google.com/file/d/1YjBhWH4scLK4B-yR_fUXeJehUmtlFoFJ/preview" width="400" height="300" allowfullscreen="allowfullscreen"></iframe>

Thanks Bini

3 Answers

Check if the attribute in your iframe are valid and compatible with for the iOS and safari version you can use: http://validator.w3.org

I was able to get this to play after disabling cross-site tracking prevention under Safari > Preferences > Privacy.

It seems to be related to ITP and cross-site tracking prevention.

Use this method. Replace "videoID" at the end of the url.

<video controls>
    <source src="https://drive.google.com/uc?export=download&id=videoID" type='video/mp4'>
</video>
Related