HTML DOM Audio defaultMuted property
Examples
The default setting audio mute:
document.getElementById("myAudio").defaultMuted = true;
try it"
Definition and Usage
defaultMuted property sets or returns whether the audio is muted by default.
Setting this property will only change the default mute state, instead of the current. To change the current mute state, use the muted property.
Browser Support
Only Google Chrome and Safari 6 browser support defaultMuted property.
grammar
Back defaultMuted properties:
audioObject .defaultMuted
Setting defaultMuted properties:
audioObject .defaultMuted=true|false
Property Value
值 | 描述 |
---|---|
true|false |
指示音频默认是否静音。
|
technical details
return value: | Boolean value that, if set the default audio mute returns true, otherwise returns false. |
---|---|
Defaults: | false |
Audio Object