Sobis
Sobis

Reputation: 1405

How do I make my HTML5 video player autoplay on iPad, like filmon.com?

I'm trying to create an HTML5 video player to automatically start streaming video. I searched a lot but I didn't achieve my goal.

Then I found www.filmon.com, where all videos start to play automatically on iPad.

Does anyone know how they did it? I looked at their JS files, but I cannot make mine start automatically.

Upvotes: 3

Views: 9248

Answers (2)

Eric Scott
Eric Scott

Reputation: 61

Apple has specifically disabled every method and workaround to autoplay video on iPads and iPhones (the "autoplay" attribute, and Javascript solutions like triggering hidden link's "onclick" event).

I have yet to find a way to autoplay on iPads and it looks like Apple is continuing to squash all efforts to do it. They state, "In Safari on iPhone OS (for all devices, including iPad), where the user may be on a cellular network and be charged per data unit, autobuffering and autoplay are disabled. No data is loaded until the user initiates it."

As a quick update I just checked out Filmon.com and the videos there no longer seem to be autoplaying on an iPad. Example: http://demand.filmon.com/distant-roads-173-cnd-ontario-ca-1 autoplays on Chrome, but not on the iPad.

Upvotes: 6

jargalan
jargalan

Reputation: 5194

I don't think that iphone or ipad play streams automatically due to high traffic.

Why don't you play it manually using script at document ready? somewhat like this:

window.onload=function(){
  var audio = document.getElementById('audio');
  audio.play();
}

Upvotes: -2

Related Questions