// JavaScript Document

// Browser sniff -- the following code does a very simple browser check and rates the
//     browser as either Internet Explorer on a Win32 platform or not, so that we
//     know to use the ActiveX model, or the plug-in Model.
var sBrowser = navigator.userAgent;
//is browser IE and on Windows?
if ((sBrowser.indexOf("IE") > -1) && (navigator.platform == "Win32")) 
{
		document.write('<div id="controls">');
			document.write('<ul>');
				document.write('<li id="play"><a name="play" id="button1" onclick="document.WMPlayer.controls.Play();" href="#" title="Play"></a></li>');
				document.write('<li id="pause"><a name="pause" id="button2" onclick="document.WMPlayer.controls.Pause();" href="#" title="Pause"></a></li>');
				document.write('<li id="stop"><a name="stop" id="button3" onclick="document.WMPlayer.controls.Pause();" href="#" title="Stop"></a></li>');
				document.write('<li id="inc_vol"><a name="inc_vol" id="button4" onclick="WMPlayer.settings.volume += 10;" href="#" title="Increase Volume"></a></li>');
				document.write('<li id="dec_vol"><a name="dec_vol" id="button5" onclick="WMPlayer.settings.volume -= 10;" href="#" title="Decrease Volume"></a></li>');
				document.write('<li id="fullscreen"><a name="fullscreen" id="button6" onclick="document.WMPlayer.fullScreen = \'true\';" href="#" title="Full Screen"></a></li>');
			document.write('</ul>');
		document.write('</div>');
}
// end browser sniff

//document.anchors("play").style.backgroundPosition="-41px -0px";


function update() {
// Store the current position of the current media item.
var TimeNow = WMPlayer.controls.currentPosition;

// Display the time remaining information.

// Use the Math.floor method to round the result down to the nearest integer.
TimeNow = Math.ceil(TimeNow);
RemTime.innerHTML = hms(TimeNow);

}

function showlen() {
  tlen = Math.floor(document.WMPlayer.currentMedia.duration);
  if (!document.WMPlayer.controls.currentPosition) {
    pos.innerHTML = hms(0) + "";
  }
  len.innerHTML = hms(tlen);
}