天天看點

jwplayer android m3u8,javascript - JW Player can not play m3u8 stream? - Stack Overflow

Perhaps it's a missing !DOCTYPE declaration that you don't have.

I don't have ability to test this personally, but try this version that also includes other fixes based on the original file.

Provider tests

Test M3U8

You need Flash to play these tests

//

jwplayer("player").setup({

file: '../m3u8/index.m3u8',

flashplayer: 'player.swf',

provider:'adaptiveProvider.swf',

height: 360,

width: 640

});

function loadStream(url) {

jwplayer("player").load({file: url,provider: 'adaptiveProvider.swf'});

jwplayer("player").play();

return false;

}

//]]>

//

$(document).ready(function() {

loadStream('http://localhost/m3u8/index.m3u8');

});

//]]>

EDIT: Note that you will have to be on the same Domain for this to work. Also, jwPlayer forum mentions that .m3u8 works only for iOS and Safari. Reference HERE.

To test a valid .m3u8 streaming playback webpage provided by LongTail Video website with your device, access this WEBPAGE. Caution when using desktop browser! It or VLC Media Player Plugin might crash with a sad face.