Refresh Ziggeo video player with new Video Token using Angular 9
I am integrating Ziggeo video player in Angular 9 application.
Ziggeo video player is not showing next video on button click.
How to update video player with new video token on button click?
-
Hi Gobind,
I believe I replied on your question in Github however I will also include info here, in case someone sees this and is interested in the same.
Once the video player is created you can not just replace the video token. What would be my suggestion is to clear our the placeholder where the player is and then create a new video player instead.
Then you can just add this to the function that is called by your own button.
Using this approach would allow you to have a previous and next video buttons, or to generate the slide of videos using their images that on click activate the video itself.
One example of this can be seen in one of our Wordpress plugins with the specific (VideoSite Playlist) video wall.
While not Angluar, it still shows code that might be helpful so I am sharing a link: https://github.com/Ziggeo/ziggeo-wp-videowalls-for-ziggeo/blob/master/assets/js/client.js#L1477
Hope this helps,
Bane0
Please sign in to leave a comment.
Comments
1 comment