Embedding Videos with the Wistia API

First, generate an embed code and embed your Wistia element within a rectangle:

<iframe src="http://fast.wistia.net/embed/iframe/c8ss0suilx" frameborder="0" scrolling="no" class="wistia_embed" name="wistia_embed" width="800" height="450"></iframe>

Next, add this JavaScript library to your document’s head:

<script src="http://fast.wistia.net/static/iframe-api-v1.js"></script>

You can edit the contents of the `…` of your exported .html file by clicking on ‘Edit HTML Head’ in the Document Inspector. Per Wistia’s docs, this library is required to interact with iframes as Wistia objects. Their docs are here: http://wistia.com/doc/embedding

Finally activate the Wistia iframe and get the API object. Set the unique element ID of your Wistia object to be 'video' and run this function 'On Scene Load' :

var wistiaEmbed = document.getElementById('video').firstChild.wistiaApi;

You can download an example document here: wistia.hype.zip (62.3 KB)