A simple myspace code sample for the player featured above: <object type="application/x-shockwave-flash"
|
Examples:
The above is sample code suitable for Myspace. It won't work AS IS. Test each red URL separate from the code to be sure it produces either the empty player or the playlist before embedding it. Note that an earlier example on the page used a table border to wrap the player. Myspace has recently disallowed tables or table borders on most of their site so the table reference was removed.
Objects:
The object and embed blocks are not the only way to embed this or any other flash object. One can gain active button or script control over nearly any aspect of a flash object by modifying it's variables and dynamically reload it. I prefer the JW player because it's well documented. See the JW javascript API page for more mind boggling examples of embedding and actively controlling the player.
Note that javascript is prohibited on Myspace so don't bother trying to embed a javascripted player on their site.
Skins:
The JW site has many skins available and requires all skins to include the flash source file for user customizations. JW also supports plugins to add functionality like collecting click statistics, adding a transparent search bar or dynamically displaying lyrics, running other javascripts on player events, displaying artwork etc. Neither player above uses a skin but the xspf home page does. To use a skin you simply append the skin parameter to the end of the flashvars "value" paramater, like the blue text below:
value="file=http://www.yoursite.com/music/xspf.php
&playlist=bottom&volume=20&frontcolor=ffffff&lightcolor=cc9900
&backcolor=000000&frontcolor=ffffff&skin=http://yoursite.com/player/skin.swf" />
Be aware that not all skins support a drop down playlist, but most do and for heavens sake, live a little; make your own!
Have fun!