Show player Modal

Code example of modal usage:
$('#myModal').on( 'show', function(){
	$('#video_wrap').html(
		'<div id="kaltura_player" style="width:525px;height:330px;"></div>'
	);
	kWidget.embed({
		'targetId': 'kaltura_player',
		'wid': '_243342',
		'uiconf_id' : '12905712',
		'entry_id' : '0_uka1msg4',
		
		// for autoplay on iOS:
		'captureClickEventForiOS': $('#autoplay').attr("checked"),
		'readyCallback': function( playerId ){
			if( ! $('#autoplay').attr("checked") ){
				// no ready callback binding needed if no autoplay: 
				return ;
			}
			// AutoPlay: issue a play on mediaReady
			var kdp = document.getElementById( playerId );
			kdp.kBind('mediaReady', function(){
				kdp.sendNotification( 'doPlay' );
			});
		}
	});
});
$('#myModal').on( 'hide', function(){
	kWidget.destroy('kaltura_player');
});