Question

I'm using the Ooyala API (http://www.ooyala.com/support/docs/player_api) to embed videos and want to dynamically change the titles as the videos change.

I've embebbed the video in the html using the following code;

   <script src="http://www.ooyala.com/player.js?width=750&height=312&embedCode=dwbjp-XdAc-w6mATLnMIuwBRxHfF5vRK"></script>

In the js file, I can then then reload the player by using;

document.getElementById('player').setQueryStringParameters({embedCode:'pzcDAxMTrAKV8Y7ClV7VbyLZE6kY4Q8d',autoplay:'1'});

As the API provides getCurrentItemTitle, I thought it would as easy as assigning this property to a var and spitting it out again like so;

$title = document.getElementById('player').getCurrentItemTitle;

.. but, this doesn't seem to work. :(

Anyone any ideas?

Many thanks,

Barry

Was it helpful?

Solution

Have you tried adding parenthesis on the end?

$title = document.getElementById('player').getCurrentItemTitle();

OTHER TIPS

doh..of course, it's a function..so needs () appended on the end..just figured it out all on my tod..

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top