Any idea how to turn off the automatic playback of Vine.co embedded videos?

I am working on a small project.

I can embed and display the specified vine.co video with

<iframe id='eFrame' src='http://vine.co/v/bJjdTLBnwx1/card' width='380' height='380' frameborder='0'></iframe>

I drag out links through Ajax to display them on the page, however now the problem is that they all start automatically, which causes a serious lag in the browser.

Does anyone know how I can add them to a body with auto play disabled ? This project is client-side, so I will be limited only to client languages. (e.g. javascript / jQuery etc.)

Thanks a lot, Cheers.

+5
source share
2 answers

, , , jQuery postMessage. :

var iframe = document.getElementById(id);

iframe.contentWindow.postMessage('pause', '*');

, .

+1

<iframe id='eFrame' src='http://vine.co/v/bJjdTLBnwx1/embed/simple' width='320' height='320' frameborder='0'></iframe>

, , .

.

-2

All Articles