开发者

javascript: is there a way too embed a blip.tv video via javascript?

Is it possible to embed a video via javascript like vimeo &开发者_StackOverflow社区 moogaloop, but for blip.tv?

Their documentation seems unclear about how to do it, they have no example and I couldn't find any by googling for about 40 minutes..

Thanks, S.


I finally came across a solution for what I wanted to do. If anybody is ever interested about it, here it is: (i'm using mootools)

function blipEmbed(episodeId) {
    var swf_id = 'embeddedPlayer';
    var moogaloop = new Swiff('http://blip.tv/scripts/flash/stratos.swf', {
        id : swf_id,
        container : 'playerHolder', /* the container's id where the swf will be embedded, i used a div */
        fullScreen: true,
        width : 1000,
        height : 500,
        vars : {
            file: "http://blip.tv/file/"+episodeId+"?skin=rss", 
            autostart: true, 
            allowm4v: true,
            showstrands: false,
            showguidebutton: false,
            showplaylist: false,
            showsharebutton: false,
            showmorebutton: false,
            showfsbutton: false,
            removebrandlink: true,
            showinfo: false,
            useoldendcap: false,
            enablejs: true
        }
    });

}

/* and for the callback, blip forces you to use this function*/

function getUpdate(changeType, param1, param2){
    if (changeType=="complete") {
        // when the video is done playing, do something
    }
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜