Reputation: 2827
I have an array of videos, and I want to initialize the player for each div that contains video.
In my JS code I build divs like:
<div id="player+{{$index}}"></div> // "player" + index is calculate dynamically by js function
Then:
dscPlayer.initialize(urlvideo,coverUrl,id);
initialize : function(urlvideo,coverUrl,id) {
flowplayer("player"+id,
{....
But I don't see the video. Any suggestions?
Upvotes: 0
Views: 328
Reputation: 7261
Glancing at the documentation, it seems you're attempting to use the "manual installation" method (i.e. you're not using the flowplayer
HTML class).
However, the global flowplayer
function doesn't seem to be used for setup, instead it is used for programmatic access to the player's behavior.
What is described in the manual setup documentation is the use of the flowplayer
jQuery plugin (not the global function).
$('player' + id).flowplayer({ ...
Disclaimer: I'm not familiar with flowplayer
at all, just trying to help interpret the documentation (which I've only glanced at), I could have easily missed something.
Upvotes: 1