我正在使用 Kaltura Player HTML v1.9.1,当用户单击外部播放器按钮时,我们需要更改媒体。问题是媒体不是 Kaltura 的条目,是外部 URL。我尝试使用 kaltura 中托管的视频更改媒体,使用 entry_id,并且效果很好。
我们的代码是:
function jsCallbackReady( playerId) {
// Get the player Object
kdp = document.getElementById(playerId);
$('a').click(function () {
kdp.sendNotification( 'changeMedia', { 'entryId' : 'http://example.org/4.mp4'});
});
}
// Player.
kWidget.embed({
'targetId': 'myVideoTarget',
'wid': '_110',
'uiconf_id' : '8705289',
'entry_id' : 'http://example.org/3.mp4',
'flashvars': {
'autoPlay': true,
},
'uiVars' : {
'streamerType' : 'http',
'sourceType' : 'url',
},
});