Try this snippet
list.onclick = function(e) {_x000D_
e.preventDefault();_x000D_
_x000D_
var elm = e.target;_x000D_
var audio = document.getElementById('audio');_x000D_
_x000D_
var source = document.getElementById('audioSource');_x000D_
source.src = elm.getAttribute('data-value');_x000D_
_x000D_
audio.load(); //call this to just preload the audio without playing_x000D_
audio.play(); //call this to play the song right away_x000D_
};
_x000D_
<ul style="list-style: none">_x000D_
<li>Audio Files_x000D_
<ul id="list">_x000D_
<li><a href="#" data-value="http://media.w3.org/2010/07/bunny/04-Death_Becomes_Fur.oga">Death_Becomes_Fur.oga</a></li>_x000D_
<li><a href="#" data-value="http://media.w3.org/2010/07/bunny/04-Death_Becomes_Fur.mp4">Death_Becomes_Fur.mp4</a></li>_x000D_
<li><a href="#" data-value="http://media.w3.org/2010/11/rrs006.oga">rrs006.oga</a></li>_x000D_
<li><a href="#" data-value="http://media.w3.org/2010/05/sound/sound_90.mp3">sound_90.mp3</a></li>_x000D_
</ul>_x000D_
</li>_x000D_
</ul>_x000D_
_x000D_
<audio id="audio" controls="controls">_x000D_
<source id="audioSource" src=""></source>_x000D_
Your browser does not support the audio format._x000D_
</audio>
_x000D_
JSFiddle http://jsfiddle.net/jm6ky/2/