You need to swap out xspf_player in WEB-INF/jsp/webPlayer.jsp. This is fairly easy as both xspf_player (the current flash player) and jw_player use xspf playlists the same way, so jw_player just swaps right in. I'm using the older 3.x version of jw_player because i'm using some of the javascript api that it has (the javascript api was changed and improved a bit, but for my purposes 3.x is easier to work with). just go to
http://www.jeroenwijering.com/?item=JW_FLV_Media_Player, grab whatever version you want (the older 3.x is available on the SVN) and read the documentation. There is also a wizard for customizing flashvars:
http://www.jeroenwijering.com/?page=wizard. It's pretty straight forward.
Here's what I'm using keep in mind I have a pretty heavily modified version of subsonic, so you'll want to probably just swap out the embed code (I stuck jw_player in the root directory, it's named player.swf):
<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="iso-8859-1" %>
<html>
<head>
<%@ include file="head.jsp" %>
<title>subs0nic</title>
<c:set var="width" value="400"/>
<c:set var="height" value="150"/>
<link rel="stylesheet" href="style/black.css" type="text/css"/>
<script type="text/javascript" src="<c:url value="/script/scripts.js"/>"></script>
<script type="text/javascript" language="javascript">
function detach() {
popupSize("webPlayer.view?detached=",'player','toolbar=no,statusbar=no,location=no,scrollbars=no,width=400,height=150');
}
</script>
<script type="text/javascript">
var currentItem;
function getUpdate(typ,pr1,pr2,pid) {
if(typ == "item") { currentItem = pr1; setTimeout("getItemData(currentItem)",100); }
};
function getItemData(idx) {
var obj = thisMovie("xspf_player").itemData(idx);
document.getElementById("songinfo").innerHTML = obj["title"];
};
// This is a javascript handler for the player and is always needed.
function thisMovie(movieName) {
if(navigator.appName.indexOf("Microsoft") != -1) {
return window[movieName];
} else {
return document[movieName];
}
};
</script>
</head>
<c:url var="playlistUrl" value="/xspfPlaylist.view">
<%-- Hack to force Flash player to reload playlist. --%>
<c:param name="dummy" value="${model.dummy}"/>
</c:url>
<c:url var="playerUrl" value="player.swf?playlist_url=${playlistUrl}&autostart=true"/>
<c:choose>
<c:when test="${model.detached}">
<body width="400" height="150" onload="window.focus();window.moveTo(300, 200);"style="background: black; margin: 0 auto; padding: 0">
<div style="position: fixed; top: 0; left: 0; width: 395px; height: 140px; margin: 0 auto; padding: 0;">
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0"
width="${width}" height="${height}">
<param name="allowScriptAccess" value="sameDomain"/>
<param name="movie" value="player.swf"/>
<param name="quality" value="high"/>
<param name="bgcolor" value="#eee"/>
<embed id="xspf_player" src="player.swf" quality="high" bgcolor="#222222" name="xspf_player" allowscriptaccess="sameDomain"
type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"
height="${height}" width="${width}" flashvars="file=${playlistUrl}&autostart=true&frontcolor=0x999999&lightcolor=0xfafafa&backcolor=0x000000&searchbar=false&autoscroll=false&displaywidth=130&overstretch=true&thumbsinplaylist=false&showicons=false&fullscreen=false"></embed>
</object>
</div>
</c:when>
<c:otherwise>
<body onLoad="detach()" class="footer">
</c:otherwise>
</c:choose>
</body>
</html>