Playlist from database, or XML/XSPF?

315 views
Skip to first unread message

trabant66

unread,
Jul 31, 2010, 9:58:48 PM7/31/10
to jPlayer: the CSS styleable jQuery audio player plugin
Is there any way to get jPlayer to pull a playlist from a mySQL
database or at least from an XML or XSPF file? I'm trying to create a
mobile version (Flash-free) of a record company website with 300+
titles in the catalog. Each album in the catalog has a playlist of 30
second clips of the album tracks on the item page. The site currently
uses the Flash-based Wimpy player and pulls the tracks and album
playlists from a mySQL database. It would be great to be able to just
pull that data out and have it dumped into jPlayer, but I'm not a
programmer so I would need a starting point to work from. The Wimpy
SQL admin will export a playlist into an XML file, and it would be
nice to be able to use that somehow. I also found an open source app
that will create an XSPF playlist of all the files in folder, so that
is another option for generating the playlist data.

I'd really like to leverage the database that is already set up so I
don't have to create playlists from scratch for the mobile site, or
at least use an XML file that I can easily generate. jPlayer seems
like the perfect solution for a player technology for a mobile
website, but hand coding 300+ playlists just isn't feasible. I'd
rather not have the audio clips at all if that's the case.

Thanks in advance for any insight on how to make this work.

Mark P

unread,
Aug 11, 2010, 10:56:14 AM8/11/10
to jPlayer: the CSS styleable jQuery audio player plugin
Hello,

jPlayer can do its part... You are really asking about jQuery and
JavaScript in general. A simple piece of jQuery can make an AJAX call
to the XML files directly and then again use jQuery to read the XML
info and populate a playlist in the browser.

http://think2loud.com/reading-xml-with-jquery/

It sounds like you'll be reading in an XML file that contains URLs to
the Playlist XML files. Anyway, you would need to know the URL of the
playlist XML so that you could read it in.

Best regards,
Mark P.

Appz

unread,
Aug 14, 2010, 12:23:07 PM8/14/10
to jPlayer: the CSS styleable jQuery audio player plugin
ThankU this was very useful
Reply all
Reply to author
Forward
0 new messages