VBulletin Embed Video Code

by Dave | nanacast

Not really related to Nanacast, but “hey” … what the heck.

If you had me hookup your VBulletin forum with Nanacast, you might be interested in this.

Embed Wistia in VBulletin

You’ll need to create a custom BB code.

Login to your admincp area, click on the Custom BB Codes link near the bottom left. Then click on Add New BB Code. If all goes well, you should be looking at something like this.

Go get the embed code from Wistia, it should look like this:

<iframe src=”http://fast.wistia.net/embed/iframe/562rncur36?controlsVisibleOnLoad=true&version=v1&videoHeight=360&videoWidth=640&volumeControl=true” allowtransparency=”true” frameborder=”0″ scrolling=”no” name=”wistia_embed” width=”640″ height=”360″></iframe>

Make sure you modify the parameters before you come back here, especially the height and width as those will always be the same in your VBulletin forum … unless you decide to modify the BB code you are now creating.

The important part of that iframe code is the 562rncur36. That will be what changes when you decide to embed another Wistia video.

Take that code and replace 562rncur36 with {param}. Yes, include the squiggly braces.

Your Wistia code should now look like:

<iframe src=”http://fast.wistia.net/embed/iframe/{param}?controlsVisibleOnLoad=true&version=v1&videoHeight=360&videoWidth=640&volumeControl=true” allowtransparency=”true” frameborder=”0″ scrolling=”no” name=”wistia_embed” width=”640″ height=”360″></iframe>

That’s Out Of The Way

Now we can get some real work done.

Click on the Add New BB Code button near the top.

Fill in the Title: Wistia, the BB Code Tag Name: wistia, paste in your fancy-pancy Wistia embed code in the Replacement box, and in the Example: [wistia]562rncur36[/wistia].

Click Save.

How To Use

From now on, when you want to embed your Wistia video in your forum, you will need to find that little chunk of code … the one that looks like the 562rncur36 and then place the wistia BB code like this: [wistia]562rncur36[/wistia].

And this is what you get …

Embed EZS3 in VBulletin

Guess what?

It is almost the same as Wistia.

You find that little chunk of code and change it to {param} and go through all of the stuff I mentioned for Wistia.

In this case, the code you want is what follows after the “flv/”.

<script type=”text/javascript”>// <![CDATA[
var playerhost = ((“https:” == document.location.protocol) ? “https://nanabuilder.s3.amazonaws.com/M4V/ezs3js/secure/” : “http://nanabuilder.s3.amazonaws.com/M4V/ezs3js/player/”); document.write(unescape(“%3Cscript src='” + playerhost + “flv/168D2633-03C9-AE68-E13DCDBA62AA0192.js?t=”+(Math.random() * 99999999)+”‘ type=’text/javascript’%3E%3C/script%3E”));
// ]]></script>

For this example, replace 168D2633-03C9-AE68-E13DCDBA62AA0192 with {param} so the code now looks like:

<script type=”text/javascript”>// <![CDATA[
var playerhost = ((“https:” == document.location.protocol) ? “https://nanabuilder.s3.amazonaws.com/M4V/ezs3js/secure/” : “http://nanabuilder.s3.amazonaws.com/M4V/ezs3js/player/”); document.write(unescape(“%3Cscript src='” + playerhost + “flv/{param}.js?t=”+(Math.random() * 99999999)+”‘ type=’text/javascript’%3E%3C/script%3E”));
// ]]></script>

If I remember right with EZS3 you might need to change some permissions inside your EZS3 account to allow videos to be embedded on specific websites.