Alrynec Alrynec - 1 year ago 166
HTML Question

How to mute an iframe?

I need to mute an iframe, but I don't know how to do it. Here is an example of what I have:

Here you can hear the music from the website on the iframe, I need to automatically mute that audio.
Hope that someone knows how to do it.

Answer Source

you can mute it by js, example: just put this in your page:

<script type="text/javascript">

you should replace "video1" by the id of your iframe, if the iframe don't have any id add an id to it as follow:

<iframe width="820" height="390" src="" id="iframeId"></iframe>
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download