Hej guys,
based on @Chiaradesignsthings code idea, I have implemented a button / image that plays a sound when you click it. The code looks as follows:
For the html on page:
`<audio id="play" src="https://coors-it.com/assets/Retro%20Desire.mp3"></audio>
<a onmouseup="playSound()" outline="none()">
<img src="https://uploads-ssl.webflow.com/601152e54d7e2c483b639b61/6011846a631c9183e4b3ca40_Sound.png">
</a>`
And for the footer code:
<script>
function playSound () {
document.getElementById('play').play();
}
</script>
For the second click I want the sound to stop playing or pausing.
Does anyone has an idea on how to realize that?
Thanks in advance,
Cedric