This is how I got it working:
1. Create a directory somewhere under the root of your cmsms site; e.g. I created the directory /var/www/mysite/modules/EnhancedXSPF/xspf/
MyPlayer/
2. Download the files
XSPF.swf and
FMP3.swf from
http://www.enricolai.com and copy them into the newly created directory
3. Edit the
EnhancedXSPF.module.php file (make a backup copy first if you want) and add the following at the end of the
getExtraParameters() function (I think it's the minimum set of parameters to get it working):
function getExtraParameters()
{
// non-preference parameters
return array(
'alpha',
'alphabetize',
...
...
'volume_level',
'folder',
'display'
);
}
4. Edit the
templates/default.tpl template (make a backup copy first) and change the following
{if $count_downloads == '0'}
{assign var='url_begin' value="$player_url?playlist_url=$playlist_url%3Fplaylist=$playlist_id%26count_downloads=0"}
{else}
{assign var='url_begin' value="$player_url?playlist_url=$playlist_url%3Fplaylist=$playlist_id"}
{/if}
to
{if $count_downloads == '0'}
{assign var='url_begin' value="$player_url?
playlist=$playlist_url%3Fplaylist=$playlist_id%26count_downloads=0"}
{else}
{assign var='url_begin' value="$player_url?
playlist=$playlist_url%3Fplaylist=$playlist_id"}
{/if}
5. Eventually reassign (chown/chmod) the original ownership and permissions to the modified files.
6. Now go to your CMSMS admin interface and select "Extensions-EnhancedXSPF" from the menu, then select the "Module Preferences" tab. Edit the
extended_player_url parameter and set it to:
http://my-host-ip/mysite/modules/Enhanc ... r/XSPF.swf
If you want to add the parameters to the Module Preferences form, you will have to edit the
SetParameters() function instead of
getExtraParameters() in the
EnhancedXSPF.module.php file, and add the extra parameters there. Then you have to edit the
action.admin_prefs.php to insert the input fields. This is something I haven't tryed yet.
7. To use your player you must now add a tag in a page, e.g.
{cms_module module="EnhancedXSPF" playlist="1" folder="http://my-host-ip/mysite/modules/Enhanc ... /MyPlayer/" display="1@. - @0@ - @"}
The "folder" parameter tells the XSPF player where to find the actual FMP3 mp3 player.
The "display" parameter tells XSPF player how to display the titles (you can read about the use of the parameters in
http://www.enricolai.com/FMP3/XSPF-flash-mp3-player.asp).
There is still an "undefined" title at the top of the playlist that I hadn't the time to adjust; I think it's a matter of display parameter settings.
Because you change the template, changing to the original player involves some editing or some file name changing and is not parametric, but DeeEye, the developer of EnhancedXSPF, who I thank for his support, will eventually work on the module to add the missing flexibility.
NOTES:
The following happens to me also if I use the original 'embedded' player (EnhancedXSPF player):
A. Setting (checking) parameters
no_direct_downloads or
count_downloads in the EnhancedXSPF module makes the playback of *some* files fail (only some of the files of the playlist).
B. The playback *speed* of some files (I suspect they are the same files mentioned in A., but I could not get the proof) is slowed down; they are normal mp3 files, some are converted from CD's, some are original mp3's. Playing them in Windows (e.g. Windows Media Player) or Linux (e.g. Rhythmbox) is ok.
Please tell me if anyone experiences a similar behaviour or find a cause or solution... or if the above is not working.
R.