//embeds flowplayer into a page
//expects comma seperated URLS to videos you want to play in
//the player in the order you want to play them
//requires SWFObject
function embedPopVideo(containerId, paths, width, height) {
	$("#videoPlayerPopout").show();
	
	playList = "";
	splitPaths = paths.split(",");
	numberOfVids = splitPaths.length;
	if (numberOfVids > 1) {
		for (var x = 0; x < numberOfVids - 1; x++) {
			playList += "{ url: '" + splitPaths[x] + "' },";
		}
	}
	//no comma on last one
	playList += "{ url: '" + splitPaths[numberOfVids - 1] + "' }";
	
	var fo = new SWFObject("http://www.zondervan.com/zondervan/Video/FlowPlayer.swf", "Video Player", width, height, "7", "#ffffff", true);
	// need this next line for local testing, it's optional if your swf is on the same domain as your html page
	fo.addParam("allowScriptAccess", "always");
	fo.addVariable("config", "{baseURL: 'http://www.zondervan.com', playList: [ " + playList + " ], initialScale: 'fit', autoPlay: true, showFullScreenButton: false, showMenu: false, showPlayListButtons: true}");
	fo.write(containerId);
}
function closeVideoPopout()
{
	document.getElementById("actualVideo").innerHTML = "";
	$("#videoPlayerPopout").hide();
}