Sample kWidget.getSources

This script enables you to generate stand alone video tags using kaltura entries.
Basic usage of kWidget.getSources looks like this:
  1. kWidget.getSources({
  2. 'partnerId': {partnerId},
  3. 'entryId': {entryId},
  4. 'callback': function( data ){
  5. // data includes an array of sources that can easily be put into a video tag:
  6. $vid = $('<video />').attr({
  7. 'title' : data.name,
  8. 'poster' : data.poster + '/width/640',
  9. })
  10. for( var i=0; i < data.sources.length; i++ ){
  11. $vid.append(
  12. $('<source />').attr( data.sources[i] )
  13. )
  14. }
  15. $('body').append( $vid )
  16. })
partnerId : entryId: