guys, I'm trying to play a sound when hovering over a button. I've tried reading trough examples but it doesn't seem to work. This is my code now:
<audio id="mySoundClip">
<source src="/sound/c_but.mp3" type="audio/mp3" />
</audio>
<script type="text/javascript">
var mysound = document.getElementById("mySoundClip");
</script>
<div class="whole">
<div id="social">
<a href="#"><img name="faceb" src="img/social/up_fb.png" width="40" onMouseOver="faceb.src='img/social/o_fb.png'; mysound.play();" onMouseOut="faceb.src='img/social/up_fb.png'" class="soc"/></a>
<a href="#"><img name="goobu" src="img/social/up_gb.png" width="40" onMouseOver="goobu.src='img/social/o_gb.png'" onMouseOut="goobu.src='img/social/up_gb.png'" class="soc"/></a>
<a href="#"><img name="myspa" src="img/social/up_ms.png" width="40" onMouseOver="myspa.src='img/social/o_ms.png'" onMouseOut="myspa.src='img/social/up_ms.png'" class="soc"/></a>
<a href="#"><img name="twitt" src="img/social/up_tw.png" width="40" onMouseOver="twitt.src='img/social/o_tw.png'" onMouseOut="twitt.src='img/social/up_tw.png'" class="soc"/></a>
</div>
</div>
As you can see, hovering over the first image - the facebook link should trigger my sound.. but it doesn't. Here is my link http://work.juanalvarezdj.com Can you help, please? What am I doing wrong?