	var objLinkCollection;	/* store a collection of Links */
	var objDivCollection;	/* store a collection of Divs */

	function InitializeMenu() 
	{
		/* get a collection of links */
		objLinkCollection = document.getElementsByTagName("A");
//		for (var j = 0; j < objLinkCollection.length; j++)
		for(var j=0;j<SongList0.length;j++)
		{
			var objA = objLinkCollection[j];
			objA.onmouseover = ShowDescription;
			objA.onmousemove = ShowDescription;
			objA.onmouseout  = HideDescription;
			objA.onclick     = LaunchPlayer;
		}

		/* get a collection of divs */
		objDivCollection = document.getElementsByTagName("div");
                objDivCollection[4].style.display="block";
                objDivCollection[5].style.display="none";
	}
	
        function BlogIT()
        {
		objDivCollection[0].style.display="none";  // Art
		objDivCollection[1].style.display="none";  // Hist
		objDivCollection[2].style.display="none";  // Play
		objDivCollection[4].style.display="none";  // Blog
		objDivCollection[5].style.display="block"; // Bio
	  }

	function ShowDescription()
	{	
		for (var i = 0; i < objLinkCollection.length; i++)
		{
			if (this == objLinkCollection[i]) {
				window.status=SongList0[i][1];
			}
		}
//		x = event.clientX + document.body.scrollLeft;/* get the mouse left position */
//		y = event.clientY + document.body.scrollTop; /* get the mouse top position  */
//		this.parentNode.childNodes(2).style.display = "block";
//		this.parentNode.childNodes(2).style.left = x + 40;
//		this.parentNode.childNodes(2).style.top = y - 170;
	}
	
	function HideDescription()
	{
		window.status="";
//		this.parentNode.childNodes(2).style.display = "none";
	}
	
	function LaunchPlayer()
	{
		var selIndex=0;
		objDivCollection[0].style.display="block"; // Art
		objDivCollection[1].style.display="block"; // Hist
		objDivCollection[2].style.display="block"; // Play
		objDivCollection[4].style.display="none";  // Blog
		objDivCollection[5].style.display="none";  // Bio
		for (var i = 0; i < objLinkCollection.length; i++)
		{
			if (this == objLinkCollection[i]) {
				window.status=SongList0[i][1];
				selIndex=i;
			}
		}

		frames['Artwork'].document.open();
		frames['Artwork'].document.write("<HTML><BODY background='http://www.brigandsfolie.com/",SongList0[selIndex][3],"'>&nbsp;</BODY></HTML>");
		frames['Artwork'].document.close();

		frames['History'].document.open();
		frames['History'].document.write("<HTML><BODY background='scroll.bmp'>");
		frames['History'].document.write("<FONT size=+1 face='Monotype Corsiva'>");
		frames['History'].document.write(SongList0[selIndex][2]);
		frames['History'].document.write("</FONT></BODY></HTML>");
		frames['History'].document.close();

   // Get Operating System - Batmosphere
   var isWin = navigator.userAgent.toLowerCase().indexOf("windows") != -1;
   if (isWin) { // Use MIME type application/x-mplayer2
      visitorOS="Windows";
   } else { // Use MIME type audio/mpeg, audio/x-wav, etc.
      visitorOS="Other";
   }

   var objTypeTag = "application/x-mplayer2"; 
     // The MIME type to load the WMP plugin in non-IE browsers on Windows
   if (visitorOS != "Windows") { objTypeTag = "audio/mpeg"}; 
     // The MIME type for Macs and Linux 

		frames['Player'].document.open();
		frames['Player'].document.writeln("<HTML><BODY STYLE='background-color:transparent'>");
                frames['Player'].document.writeln("<font style='font-size:10px;'>&copy;2008 Brigands&#39; Folie</font><br>"); 
                frames['Player'].document.writeln("<object width='280' height='69'>"); // Width is the WMP minimum. Height = 45 (WMP controls) + 24 (WMP status bar) 
                frames['Player'].document.writeln("<param name='type' value='" + objTypeTag + "'>");
                frames['Player'].document.writeln("<param name='src' value='http://www.brigandsfolie.com/Music/" + SongList0[selIndex][4] + "'>");
                frames['Player'].document.writeln("<param name='autostart' value='1'>");
                frames['Player'].document.writeln("<param name='showcontrols' value='1'>");
                frames['Player'].document.writeln("<param name='showstatusbar' value='1'>");
                frames['Player'].document.writeln("<embed src ='http://www.brigandsfolie.com/Music/" + SongList0[selIndex][4] + "' type='" + objTypeTag + "' autoplay='true' autostart='1' width='280' height='69' controller='1' showstatusbar='1' bgcolor='#351812'></embed>"); 
   
                  // Firefox and Opera Win require both autostart and autoplay
                frames['Player'].document.writeln("</object>");
		frames['Player'].document.write("</BODY></HTML>");
		frames['Player'].document.close();  
	}
