0
I have an HTML5 player using the tag <video>
, only that I have the video (which is streamed via DASH protocol) to be loaded to the tag using a bookstore javascript. I need to have exactly the same video in a popup that the user can open, and here comes the problem: if I load the video using the above bookstore, past two, three openings the page can no longer open the videos, so I thought of copying the HTML from ` already processed, which would prevent further use of the bookstore. I upload the video like this:
var url = videoOut + 'videorecording/' + videoguid + '/manifest.mpd';
var player = dashjs.MediaPlayer().create();
var videoPlayer = document.querySelector('#videoPlayerPopUp');
player.initialize(videoPlayer, url, false);
I have this code(1) to try to copy the player above without having to use the bookstore again:
var playerHTML =document.getElementById("hero-unit").innerHTML;
document.getElementById("videoPaste").innerHTML = playerHTML;
within the hero-unit
i have this HTML:
<video width="380px" height="288px" id="videoPlayer" controls="" preload="auto" src="blob:http://localhost/25ac2810-36ef-452c-844b-cad58a2773cf"></video>
I thought the above JS code(1) would copy exactly that, but what I have on videoPaste
this is it:
<video width="380px" height="288px" id="videoPlayer" controls="" preload="auto"></video>
It’s because the video has to be uploaded through the bookstore or I’m copying it wrong?
take a look at this question and its answers: https://answall.com/q/4321/3082 will definitely help you
– Paulo Roberto Rosa
@Pauloroberto gets exactly the same result using the
clone
– ihavenokia
Can you put an example running here on your question or http://jsfiddle.net ? would be ideal for people to try
– Paulo Roberto Rosa