Skip to content Skip to sidebar Skip to footer

Youtube Api Not Muting In Safari (not Ios)

I have initialized my player with the code below. It mutes fine in Chrome, FireFox, and IE, but not Safari. Any thoughts amigos? function onYouTubeIframeAPIReady() { player = n

Solution 1:

Just add some code in your onPlayerReady():

function onPlayerReady(event) {
event.target.mute();
}

or you can create a separate function for mute:

function onMute() {
player.mute();
}

function onUnMute() {
player.unMute();
}

Follow the guide code in youtube api document and jsfiddle sample.

Solution 2:

The problem ended up being that the onPlayerReady event wasn't firing. Apparently this is somewhat of a known issue and isn't terribly well documented in the YouTube API. Here's a link to the answer.

Post a Comment for "Youtube Api Not Muting In Safari (not Ios)"