SYMPTOMS: Each Mediafront Player in a view plays short mp3 files correctly on Desktop (html5 and Flash) and iPad (html5) and iPhone IOS Simulator but not iPhone (html5).
This is an edited version of the original issue description:
Mediafront created preload="metadata" properties on each audio tag even though I had requested "auto load" in Mediafront's UI. This seems to be correct because, since IOS 4, Apple ignores preload="auto" on mobile Safari.
However, only one (or sometimes two) of the four Mediafront players on our home page play at all on the iPhone Safari. iPad Safari plays them all: each one when Play is clicked.
BTW, I did notice that Mediafront populates one of the Mediafront players duration fields on the iPhone (one that actually plays) whereas *all* the iPad's players have zero duration. Could this mean that Safari is not consistently honouring the audio tag's request to preload the metadata of every audio tag?
Or could it mean there is some race condition ..... and/ or that Mediafront is not picking up the onloadedmetadata event? This is a bit beyond my area of expertise.
The Safari web inspector shows the audio files are not downloaded from the server (on page load) ... as I would expect them not to be ... and shows just little grey blobs in the timeline. It shows this on both iPad and iPhone ... but the iPad will play the audio correctly when asked to by the visitor.
Let me know if I can provide better diagnostic data .... or you could take an iPhone to http://misfitstheatre.com and see what I mean.
As I said, iPad and desktop browsers do exactly what they should. It's only the iPhone that won't do it right.
Further update:
Using Adobe Edge on the iPhone and Edge Inspector on the Mac to inspect the generated HTML, every audio Mediafront player behaved as it should on the iPhone.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | mediafront-omitFiringiPhonePlay-1819204-5.patch | 595 bytes | iainh |
Comments
Comment #1
travist commentedWhen you say 'EXPECTED'.... are you saying this is how MediaFront does behave and IS expected, or are you saying this is what is expected but NOT how MediaFront behaves. If it is the first one, then I am leaning toward that you either A) have a media file that is incompatible with certain versions of iOS, or it is possible that I am not setting up the video element with all the necessary pieces that iOS expects. I think this needs more investigation.
Comment #2
iainh commented@travist please see attempt at clearer bug description.
Looking more and more like an iPhone Safari bug.
Comment #3
iainh commentedIn response to point A)
Both iPhones and the iPad are at IOS6. The iPad plays every audio track properly. Neither of the iPhones do. The iPhones will play one or two of the tracks but the others just show "marching ants" when play is clicked.
Comment #3.0
iainh commentediPhone Simulator added as OK case
Comment #3.1
iainh commentedClearer description
Comment #4
iainh commentedThe following two JavaScript logs show how, on the iPhone, without any user interaction, the behaviours is completely different from the behaviour on the iPad. On the iPhone it appears that the play event is being triggered erroneously ... by what or whom?
The iPad case
After this sequence of events, all mediafront players play properly when tapped.
The iPhone case
After this only one (or two) players will play when tapped.
Comment #5
iainh commentedHere's a patch that mitigates the problem on the iPhone IOS 6.0 without adversely affecting the iPad IOS 6.0.
It does not trigger the play event when isIDevice is detected but leaves it to pause and onLoaded as before.
Note that this patch is effective only when the source js files are loaded i.e. when Debug is set on.
For it to work with Debug off (see Mediafront Presets UI) you'd have to run the makefile that compresses the source files.
Comment #6
travist commentediainH,
I commend you for your efforts. I committed your patch with attribution. http://drupalcode.org/project/mediafront.git/commit/8324d82
Thanks again.
Travis.
Comment #7.0
(not verified) commentedAdobe Edge experience