YouTube Autoplay does not work with iFrame
<p>My website has a player for multiple videos. I've been adapting the code to use YouTube's iframe API as the player. I can't get the videos to autoplay.</p>
<p>Here's the relevant code:</p>
<pre class="lang-html prettyprint-override"><code>&lt;body&gt;
    &lt;iframe id=&quot;existing-iframe-example&quot;
        width=&quot;640&quot; height=&quot;360&quot;
        src=&quot;https://www.youtube.com/embed/-SFcIUEvNOQ?   autoplay=1&amp;;enablejsapi=1&quot;
        frameborder=&quot;0&quot;
        autoplay=&quot;1&quot;
        style=&quot;border: solid 4px #37474F&quot;
    &gt;&lt;/iframe&gt;
    &lt;div id=&quot;player&quot;&gt;&lt;/div&gt;

    &lt;div id=&quot;movieButtons&quot; class=&quot;movieButtons&quot;&gt;
    &lt;button class=&quot;movieButton&quot; data-movieAdr=&quot;1-VjtC939_Q&quot;&gt;Memorial Slide Show&lt;/button&gt;
</code></pre>
<p>The rest is standard YouTube iframe API script. You can see I tried setting <code>autoplay=1</code> as both an iframe parameter and as part of the iframe src.  I've also tried including it in the data in the button.  None of these seems to work. The vids load when the buttons are clicked, but they don't autoplay.</p>