I am creating a simulation page for an application. It requires a set of button controls to Play, Pause and Stop sample music. I read some questions on stackoverflow to get the controls working. Some questions that I referred were:
- Accessing hidden embedded quicktime audio
- How to USE <embed> tag for music player control?
- how can use JavaScript to control audio in the embed tag
- Cross-platform, cross-browser way to play sound from Javascript?
My problem starts when I set hidden="true" in embed tag and try to call javascript function. I have tried putting tag in a hidden div but it does not work.
Embed tag code:
<embed src="abc.mp3" AutoStart="false" loop="false" height="0" width="0" hidden="true" />
Javascript to access embed tag methods.
document.embeds[0].Play();
cheers