Site hosted by Angelfire.com: Build your free website today!

XSPF WEB MUSIC PLAYER

Created by: Fabricio Zuardi

Revised by: Lacy Morrow
This page last updated: October 26, 2006

PLEASE VISIT http://geekkid.net/jukebox/creator/ FOR UP TO DATE PLAYLIST FORMATTING, AND A PLAYLIST CREATOR. CHECK http://blog.geekkid.net/ FOR PLAYER UPDATES AND CHANGES.

 

DESCRIPTION

TO-DO

PARAMETERS

USAGE

EXAMPLES

PLAYLIST

CHANGE LOG

 

Description

XSPF Web Music Player is a flash-based web application that uses xspf playlist format to play mp3 songs. XSPF is the XML Shareable Playlist Format. The software is written in Actionscript 2 and compiled for Flash Player 7.0 and above.

Load external playlists, FLV videos, and links. SWF support coming soon.

top

To-do

SWF Video

Customization

Mouseover Color

top

Parameters
  • playlist_url : the url of the xspf file to load
  • alpha : percent of color change, only works with custom color
  • alphabetize : boolean value to alphabetize playlist
  • autoplay : boolean value that makes the playlist load and the music start without the initial user click
  • autoload : boolean value that makes the playlist load without the initial user click
  • buffer : seconds to preload video before playing, exclude for automatic
  • color : six digit hex value to change the players color
  • gotoany : boolean value that forces travel to unknown URLs
  • image : url for a jpg image that is shown when autoplay is off
  • infourl : global info url for all songs, replaces playlist info urls
  • loadurl : url linking to a text file containing all variables. cuts down on html coding and file sizes, one file can be used by many players
  • load_message : message displayed after autoload
  • main_image : global image url, replaces all playlist images
  • mainurl : right-click "about" url
  • no_continue : boolean value to turn off automatic song changing
  • player_title : the text to replace the players default's
  • repeat : boolean value to set repeat
  • repeat_playlist : boolean value to repeat the playlist
  • setup : boolean value to turn on special manager features such as auto-update. more to come.
  • shuffle : boolean value to set shuffle
  • start_track : track number for beginning track
  • statsurl : url to an external script that can collect POST values. Can collect playSong and annotation
  • timedisplay : numerical value to show time counter; 0:off, 1:all, 2:elapsed, 3:duration, 4:countdown
  • useId3 : boolean value that forces id3 tag use in the slim player. Can be helpful, but not recommended
  • volume_level : starting volume level


  • The music player can also be used to play single mp3 files instead of playlists, the parameters are:
  • song_title : the text to replace the players default's
  • song_url : the url of the single mp3 you want to play

top

Usage

The player receives the parameters on the query string, the most important parameter is the playlist_url, that tells the player which xspf playlist to play, if you leave it blank the player will play a default playlist.

Some examples of how to load the playlists:

LINK:

http://musicplayer.sourceforge.net/xspf_player.swf?playlist_url=http://webjay.org/by/hideout/zuardi05.xspf&repeat_playlist=true


EMBED:

<object type="application/x-shockwave-flash" width="400" height="170" data="http://musicplayer.sourceforge.net/xspf_player.swf?playlist_url=http://yourdomain.com/yourplaylistlist.xspf"> <param name="movie" value="http://musicplayer.sourceforge.net/xspf_player.swf?playlist_url=http://yourdomain.com/yourplaylistlist.xspf" /> </object>

top

Examples

http://musicplayer.sourceforge.net/xspf_player.swf?playlist_url=http://yourdomain.com/yourplaylistlist.xspf&shuffle=1&radio_mode=1&mainurl=http://yourdomain.com&autoplay=1

http://yourdomain.com/xspf_player.swf?song_url=http://yourdomain.com/yoursong.mp3&main_image=http://yourdomain.com&song_title=HelloGoodbye&infourl=http://yourdomain.com&autoplay=1

top

 

Playlist

The XSPF playlist format is as follows:

<?xml version="1.0" encoding="UTF-8"?>
<playlist version="0" xmlns="http://xspf.org/ns/0/">
<trackList>
<track><location>http://yourdomain.com/music/Gone.mp3</location><creator>Ben Folds </creator><song>Gone</song><image>http://yourdomain.com/images/ben.jpg</image><info>http://www.benfolds.com</info><meta rel="http://geekkid.net/type">audio</meta></track>
<track><location>http://yourdomain.com/music/E-Pro.mp3</location><creator>Beck</creator><title>E-Pro</title><image>http://yourdomain.com/images/beck.jpg</image><info>http://www.beck.com</info></track>

</trackList>
</playlist>

Tags used are:

location

info

image

creator

title

annotation

meta rel="http://geekkid.net/type"

  • type, image and info tags are optional.
  • annotation and creator/title are interchangeable. creator/title provides more functionality
  • TYPE PROVIDES A TELLS THE PLAYER HOW TO HANDLE THE MEDIA, HOWEVER, THE PLAYER CAN USUALLY CHOOSE FOR ITSELF AUTOMATICALLY. ONLY FILL IN IF THE URL IS UNUSUAL. TYPE TAGS ARE ALL LOWERCASE.
  • TYPES ARE:
  1. audio
  2. video
  3. playlist
  4. link

top

 

Change Log

Added color support

Added no_continue option

Added Amazon API photo query

Added scroll wheel support

Added right-click info url

Added alphabetize function

Added main image option

Added shuffle option

Added repeat option

Added start_track option

Added main_image option

Added mainurl option

Added skip bar

Added playlist load

Added video

Added video fade

Added link support

Added auto-update

Added MediaCheck

Revised object placement

Revised volume button

Revised right-click menu

Revised code

Revised xml handling

Removed info_text option

Removed playlist_size option

Removed Radio Mode

top

 

 

Copyright (c) 2005, Fabricio Zuardi
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
* Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.