Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

sound on click javascript

<button onclick="playSound()">Play</button>

<script>
let playSound = () => new Audio("src.mp3").play();
</scirpt>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #sound #click #javascript
ADD COMMENT
Topic
Name
5+4 =