HTML5: How to pause when using Onclick for custom button? -
i'm using following code found on iphone app i'm working on,
<a onclick="this.firstchild.play()"> <audio src=".."></audio> here's insert custom player button </a>
but can't pause music, can tell me should insert pause()
?
how started? test here on fiddle.
<audio id="player" src=".."></audio> <a href="javascript:;" onclick="document.getelementbyid('player').play();">play</a> <a href="javascript:;" onclick="document.getelementbyid('player').pause();">pause</a>
Comments
Post a Comment