// JavaScript Document
// Pop-Up Embedder Script by David Battino, www.batmosphere.com
// Version 2006-05-31  
// OK to use if this notice is included
   
function BatmoAudioPop(filedesc,filepath,WindowNumber) 
{
    PlayerWin = window.open('',WindowNumber,'width=320,height=290,top=75,left=75,screenX=75,screenY=75,resizable=0,scrollbars=0,titlebar=0,toolbar=0,menubar=0,status=0,directories=0');

    PlayerWin.focus();
    PlayerWin.document.writeln("<html><head><title>Audio Sermon Player</title></head>");
    PlayerWin.document.writeln("<body bgcolor='#364F07'>"); // specify background img if desired
    PlayerWin.document.writeln("<div align='center'><img src='http://jdemos.247webmedia.com/TRR/wp-content/themes/WP-Template/images/tastingroomradio_logo.png'><br />");
    PlayerWin.document.writeln("<br><b style ='font-size:18px;color:#d5d5d5;font-family:Lucida,sans-serif;line-height:1.6'>" + filedesc + "</b><br />");
    PlayerWin.document.writeln("<br><object type='application/x-shockwave-flash' data='http://jdemos.247webmedia.com/TRR/mp3player.swf' width='250' height='20'>");
    PlayerWin.document.writeln("<param name='movie' value='http://www.summitnorthwest.org/sermons/mp3player.swf'>");
    PlayerWin.document.writeln("<param name='wmode' value='transparent'>");
    PlayerWin.document.writeln("<param name='FlashVars' value='mp3=" + filepath + "&width=250&autoplay=1&loop=true&showvolume=1&showloading=always&volumewidth=50&volumeheight=8&loadingcolor=B4B6B3&sliderovercolor=0052B6&buttonovercolor=0052B6&sliderwidth=12'>");
    PlayerWin.document.writeln("</object></div>");
    
    PlayerWin.document.writeln("<form><br><div align='center'><input type='button' value='Close this window' onclick='javascript:window.close();' style='margin-bottom: 5px;'></div></form>");
    PlayerWin.document.writeln("</body></html>");

    PlayerWin.document.close(); // "Finalizes" new window
}
