
f_sound=0; divSound=document.getElementById('sound');

thisSwitch=document.getElementById('switch'); if(thisSwitch) {thisSwitch.innerHTML='audio ON';}


function Play(sound){ play_wma(sound);}

<!-- Google est un peu lent au démarrage des mp3-->
function play_mp3(sound) { sound=sound+'.mp3';
if(f_sound==1) {f_sound=0; if(thisSwitch) thisSwitch.innerHTML='audio ON'; return divSound.innerHTML = ''};
f_sound=1; if(thisSwitch) thisSwitch.innerHTML='audio OFF';
return	divSound.innerHTML = '<object type="" data="'+sound+'" id="object_sound"><param name="filename" value="'+sound+'" /><param name="autostart" value="true" /></object>';
}

<!--  Safari lit mal les wma -->
function play_wma(sound) { sound=sound+'.wma';
if(f_sound==1) {f_sound=0; if(thisSwitch) thisSwitch.innerHTML='audio ON'; return divSound.innerHTML = ''};
f_sound=1; if(thisSwitch) thisSwitch.innerHTML='audio OFF';
return	divSound.innerHTML = '<object type="audio/x-ms-wma" data="'+sound+'" id="object_sound"><param name="filename" value="'+sound+'" /><param name="autostart" value="true" /></object>';
}

function stop_music() { thisSwitch.innerHTML='audio ON'; return divSound.innerHTML = '';}
