This guide will show you how to implement the Treepodia Dynamic Video Player integration code and show your videos. Embedding the video is recommended for best viewing quality, and a best practice for working with online video.
Including Treepodia Dynamic Video Player script
In order to integrate with Treepodia’s platform, the Treepodia script should be included in the body of the relevant pages required for integration. Note the below script is suitable for both secure (https) and non-secure (http) pages.
Once the “dynamic.video.player.min.js” script has loaded, it will automatically invoke the function “initTreepodiaDynamicVideoPlayer(player)” on the loading page. The function will run only after the page has completed loading.
Creating a placeholder to display the video
The last step to embed the video is to create a placeholder for it. The placeholder is video element and should have a trpd-player attribute.
<video id="trpdPlayer" trpd-player></video>