Embedded youtube video autoplay

Plus d'informations
il y a 3 ans 6 mois #140163 par larschrjensen01
I've run into a quaint problem. I design questionnaires in which people see an embedded youtube video and then answer a few questions related to that video. I randomize who gets to see which video by running the rand function and then setting a selection criteria based on the output of that function. I embed the youtube video in the following way:
<iframe width="560" height="315" src="https://www.youtube.com/embed/0r7x19mw-tU?rel=0&amp;controls=0&amp;showinfo=0;autoplay=1" frameborder="0" allowfullscreen></iframe>
This has worked for years, but now when a video is played the audio of the other videos are also played back at the same time. However, this happens only when autoplay toggle is on as in the above example. Of course it's not a big deal to have users press the play button, I'm just wondering what's causing this behavior. Does anyone have an idea of what's going on?

Connexion ou Créer un compte pour participer à la conversation.

LimeSurvey Partners
Plus d'informations
il y a 3 ans 6 mois #140173 par tpartner
Réponse de tpartner sur le sujet Embedded youtube video autoplay
To be honest, if you have several videos (some hidden) in the same page, all set to autoplay, I don't know why you didn't get that audio in the past. Hiding the iframe via CSS or JavaScript (as in the case of irrelevant questions) won't prevent the auto-play from kicking in.

Perhaps using something like a fancyBox modal, where the iframe isn't initialized until the modal is displayed would work - fancybox.net/

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Official LimeSurvey Partner - partnersurveys.com

Connexion ou Créer un compte pour participer à la conversation.

Commencez dès maintenant !

Créez simplement un compte et commencez à utiliser LimeSurvey dès aujourd'hui.

Inscrivez-vous maintenant

Inscrivez-vous à notre Newsletter!