Audio - Autoplay on first slide

Audio - autoplay does not work on first slide.

Thanks

falcon's picture

Are you on a PC/Mac or a mobile device`?

PC, Firefox, Drupal

falcon's picture

Sounds like a bug. Thank you for reporting! (On mobile it isn't possible to make it work, but possible on PC)

Is there a reason why this would not work on mobile devices?

falcon's picture

A website shouldn't be able to start playing video or audio automatically because it uses lots of bandwidth. The mobile checks if playing the audio is triggered by a click on the page or not. If it isn't it won't start playing.

Thank you. Much as I found (after a bit of googling). Do you know if the click needs to be a specific one of the audio element, or could it be anything that then invokes the play() method?

falcon's picture

Can be any click as long as it is in the stack that ended up calling the play method afaik
janilemm@gmail.com's picture

Hi!

I was recently able to reproduce this one on both in Moodle and Drupal, with following OS's / browsers:

  • Mac/Firefox (newest version)
  • PC/IE 11

Actually, these browsers are not playing audio at all - it is not depending if autoplay is on/off.
Test audio is on Course Presentation slide.

On Mac/Chrome and Mac/Safari (newest versions) I can't reproduce this.

Cheers,

Jani

janilemm@gmail.com's picture

Hi!

Just done some more testing, and it seems to be that this issue is related to .wav audiofiles only.
Changed the audiofile into .mp3 file and it works fine with Firefox as well.

It would be nice if you can confirm if this is related to .wav only :-)

Best regards,
Jani

BV52's picture

Hi Jani,

Thank you for the information. However I cannot reproduce the issue on my end, I'm using Mac with Firefox V 66.0.2 (64-bit). Do you have a sample content that we can check?

-BV52

janilemm@gmail.com's picture

Hi,

Sure - here's test content, created in h5p.org.

Here's my observations:

  • If audio is on the first slide of course presentation, it is no playing on autoplay (all browsers) before user has navigated away from first slide and then back. This is not depending if the audio is mp3 or wav.
  • Wav audio examples on slide 4 and 5 doesn't played at all at Firefox & IE11 but are OK with Chrome, Safari and Edge.

Cheers,

Jani

BV52's picture

Hi Jani,

Thank you for the additional information. There is an existing bug report for the auto-play issue on the first slide and you can follow the progress here. For the other issue I've created a separate report here.

-BV52 

janilemm@gmail.com's picture

Hi BV,

Thank you confirming this.

Cheers,
Jani

janilemm@gmail.com's picture

Hi,

I was able to reproduce this in H5P.org, Drupal & Moodle, on these OS's / browsers:

  • Win/IE 11
  • Mac/Firefox (newest version)

It seems that these browsers doesn't play audio at all - it is not depending if autoplay is on/off.
My test audio is on Course presentation slide. Tested on several workstations.

On Chrome (both OS's) and Edge, audio works fine.

Hopes this helps you to solve this issue.

Cheers,

Jani

Hello,
We are also having the same issue. First slides of all modules do not auto play. However, it seemed to work when we started to build the content and the issue did not surface. Only after we built many modules we discovered the issue. I look forward to hear a resolve on this issue.
Anyone has any workarounds? It seems just adding a heading slide with no audio in the beginning seems to work.
Ranjana Verma

otacke's picture

Hi Rverma!

I am not entirely sure if that's a problem with H5P or simply browsers becoming more strict when it comes to autoplaying audio.

Best,
Oliver