views:

128

answers:

4

I am creating a little JavaScript music player that sits on the btottom of the page, a lot like streampad. But streampad uses a flash progress bar for the song and JavaScript for everything else and I am having a hard time finding anyone who does this with JavaScript alone. Can anyone point me in the right direction on how this can be done (preferably without using HTML5)?

+5  A: 

There's no way to do this with just Javascript, without going into html5 (the audio tag).

SoundManager 2 has a hidden flash component, and the UI is completely in JS. It's up to you to implement a seekbar or whatever you want, but there's a whole lot of example code. SM2 seems pretty popular, and is used by a number of big sites (Soundcloud, Last.fm, Muxtape).

Ycros
sound manager is great, thanks.
pfunc
A: 

You can't do that without HTML 5 or Flash.

You could however create an hidden flash player and control it via javascript using External Interfaces.

marcgg
A: 

Maybe you can use a library that implements a progress bar using html5 and javascript, see RGraph: http://www.rgraph.net/examples/progress.html

Sijin
I've thought about this, but need a backup, so I guess I might have to do html5 and flash. That's annoying.
pfunc
+1  A: 

i think you may found usefull look at theese:

Monitoring Loading Progress of SWFs

http://code.google.com/p/swfsound/

SWFSound is based on SWFObject and allows cross-plattform, cross-browser sound support for HTML/JavaScript using Flash Player 8 and higher.

http://code.google.com/p/swfobject/

SWFObject is an easy-to-use and standards-friendly method to embed Flash content, which utilizes one small JavaScript file

just some example

http://www.happyworm.com/jquery/jplayer/

http://www.bauer.uh.edu/parks/video3.htm

aSeptik
Thanks, I'd prefer not to use a plugin and just do something custom, but this is still cool to look into.
pfunc
Jplayer looks pretty neat, does html5 with a fallback to flash.
Ycros