I am using sound manager 2 for giving sound to my site.. Now i want mute and unmute sound on
clicking a button. I tried mute()
and unmute()
functions. But didnt get the result.
My code for mute is :
function mutesound(){
soundManager.mute(); // mute all sounds
soundManager.createSound({
id: 'msound',
url: 'folder/sound/click.mp3',
autoLoad:true,
onload: function() {
soundManager.mute('msound');
}
});
}
Can someone help me please?