Search.../

volume

Sets or gets an audio player's volume.

Description

Setting the volume property sets the audio player's percentage of total volume. Set the value to a number between 0 and 100.

Getting the volume property returns the audio player's current percentage of total volume.

Note: The actual volume heard by a site visitor depends on the value of the volume property and the volume settings on the visitor's device.

Type:

numberRead & Write

Was this helpful?

Get an audio player's volume

Copy Code
1let volume = $w("#myAudioPlayer").volume // 42
Set an audio player's volume

Copy Code
1$w("#myAudioPlayer").volume = 42;