title: Access Flash Media Playback events and methods via JavaScript
body: <p>Does anyone know if <a href="http://www.osmf.org/" rel="nofollow">Flash Media Playback</a> support some API because  I need to handle a few methods/events via <code>javascript</code> like:</p>
  
  <ol>
  <li>Play</li>
  <li>Pause</li>
  <li>Stop</li>
  <li>Streaming is ended</li>
  <li>Streaming is started</li>
  <li>Streaming error</li>
  </ol>
  
  <p>I need the all things like it has <a href="http://wirehazard.com/player/OSMFPlayerJS.html" rel="nofollow">Grab Player</a>. But the <a href="http://help.adobe.com/en_US/OSMF/1.0/Dev/WSc6f922f643dd2e6d-55c3771112a39ae1fb5-8000.html" rel="nofollow">docs</a> says that we have to implement it.
  Thanks!!</p>
  
  <p>P.S. Basic FMP implementation is the following:</p>
  
  <pre><code>  &lt;object width="600" height="409"&gt; &lt;param name="movie" value="http://fpdownload.adobe.com/strobe/FlashMediaPlayback.swf"&gt;&lt;/param&gt;&lt;param name="flashvars" value="src=http%3A%2F%2Fosmf.org%2Fvideos%2Fcathy2.flv&amp;poster=http%3A%2F%2Fosmf.org%2Fimages%2Fposter_cathy_fmp.jpg"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://fpdownload.adobe.com/strobe/FlashMediaPlayback.swf" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="600" height="409" flashvars="src=http%3A%2F%2Fosmf.org%2Fvideos%2Fcathy2.flv&amp;poster=http%3A%2F%2Fosmf.org%2Fimages%2Fposter_cathy_fmp.jpg"&gt;&lt;/embed&gt;&lt;/object&gt;
  </code></pre>