audio.stopAudio element

getAudio(id).stop() (since beta 0.3)

Stops the playback of the audio and goes back to the start of it, making it impossible to resume from the current position later.

Example:

[js highlight=”9″ try=”true”]newAudio(“sentence”, “test.mp3”)
.play()
,
newTimer(“preview”, 750)
.start()
.wait()
,
getAudio(“sentence”)
.stop()[/js]

Starts playing the file test.mp3 and stops it after 750ms. Calling play later on would not resume playback from there, but start all over from the beginning.