Skip to main content
OCLC Support

Embed external video stream

If you have records in CONTENTdm that are URL references to an outside streaming service, you can use JavaScript to read the stream URL and embed the video or audio player directly in the CONTENTdm item page. This example will work for YouTube, Vimeo, and Kaltura embed links. This example can be modified to work with any external service that provides a method for embedding some kind of viewer or player.

This implementation assumes that you have stored the streaming URL from the third-party service as a “URL Item” in CONTENTdm. The code looks for the URL item link and replaces it with an iframe or div containing the embedded viewer.