Default behavior:
Before the the opening A tag for file #1 download the file after the closing A tag.
Before the the opening A tag for file #2 after the closing A tag (no text between the opening and closing A tags).

Conditional behavior:
Before the the opening A tag for file #3 download the file after the closing A tag.
Before the the opening A tag for file #4 after the closing A tag (no text between the opening and closing A tags).


This pages uses JavaScript to insert three Flash-based mp3 players immediately after a link to an MP3 file. The first player is a 17x17 pixel play button (XSPF Button Player), the second is a 17x220 pixel slim player (XSPF Player), and the third is a 24x290 player (1pixelout) . CSS is used to determine which of the players is presented on the page. Further CSS and HTML can be combined in instances where a play button is desirable on one link, a slim player is desirable on another, and the 1pixelout player is desirable on a third.

If this JavaScript was added to a sitewide JavaScript then insertAudioPlayers() could be executed by the onload event, or by a function that is executed by the onload event. The result would be the automatic insertion of the players next to every hyperlink to an MP3 file. This would take place on every page of the Web site.

NOTE: This implemenetation uses XSPF player and the 1pixelout player but it's conceivable that other Flash-based players could be inserted in the same way.