function putflash (src, width, height, bgcolor, wmode,altimg) {  // Src - URL файла swf . Width - ширина object. Height - высота object. Bgcolor - цвет фона.Wmode - параметр wmode ("opaque", "transporent")

       if (isFlash())	{

	document.write('<div style="width:'+width+'px; height:'+height+'px; overflow: hide;"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+width+'" height="'+height+'">');
	document.write('<param name="movie" value="'+src+'">');
	if (wmode != 'none') {
		document.write('<param name="wmode" value="'+wmode+'">');
	}
	document.write('<param name="bgcolor" value="'+bgcolor+'">');
	document.write('<param name="quality" value="high">');
	document.write('<embed src="'+src+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'"></embed>');
	document.write('</object></div>');
       } else {
	document.write('<img src='+altimg+'>');
       }
}


 function isFlash() {
return true;
        var shock = false;

        for (i=0; i < navigator.plugins.length; i++) {


           if (navigator.plugins[i].name.indexOf("Flash") != -1)
              shock = true;
        }
        return shock;
}






function doPlayer(musicURL,width,height) {

src="/player.swf?autorun=1&file="+musicURL;


document.getElementById('player').innerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+width+'" height="'+height+'"><param name="movie" value="'+src+'"><param name="quality" value="high"><embed src="'+src+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'"><param name="bgcolor" value="#FFFFFF"></object>'+'<p><a href='+musicURL+'></a></p>';


}
