swf streaming audio player

Tag: flex , audio , swf , mxml , mxmlc Author: qq181073788 Date: 2010-10-07

i am New to flex.Can any one point me to a small piece of mxml code which plays audio files(mp3,wav.....) also which has the capabilities to pause, play, stop.... the audio file.

Also this file would be embedded in a html file later on..

Other Answer1

You could code that yourself. If you're new to Flex, it would be good practice :)

For the mp3 handling look at the Sound class and related classes such as the SoundChannel class. The docs should have some examples on how to implement them, and since you're using Flex the UI components should be fairly straightforward.

Now , if you need to embed that in an HTML file, you'd have to produce a swf, in which case Flex is a bit overkill! You should look at doing this in Actionscript, the resulting swf will be much lighter.

Finally, if you can't be bothered to code this yourself, there are plenty of mp3 players out there!