Is it possible to do a javascript action after play button is pushed? I know I will need to use onStateChange function form Youtube's API. But I really don't know where to start? Any help? Thank you.
--
I have also found something here: http://apiblog.youtube.com/2011/01/introducing-javascript-player-api-for.html
http://code.google.com/apis/ajax/playground/?exp=youtube#polling_the_player
Hey here is the answer . http://jsfiddle.net/masiha/4mEDR/ Enjoy ...let me know if you have more qtns
Here's a solution that you should be able to extend easily: http://jsbin.com/evagof
Maybe Youtube made some changes since this question was posted, but most of the answers didn't work. I found that the easiest way was to use the iframe_api (https://developers.google.com/youtube/iframe_api_reference)
Here is an example
https://thimble.webmaker.org/en-US/project/39354/edit