Forum Moderators: open
<script type="text/javascript">
var soundfile="sound/sidebar.wav" //path to sound file, or pass in filename directly into playsound()
function playsound(soundfile){
if (document.all && document.getElementById){
document.getElementById("soundeffect").src="" //reset first in case of problems
document.getElementById("soundeffect").src=soundfile
}
}
function bindsound(tag, soundfile, masterElement){
if (!window.event) return
var source=event.srcElement
while (source!=masterElement && source.tagName!="HTML"){
if (source.tagName==tag.toUpperCase()){
playsound(soundfile)
break
}
source=source.parentElement
}
}
</script>
<a href="#" onMouseover="playsound(soundfile)">Any Link</a>
</html>
>>>
Here's an article that might give you some ideas, though: [ask.metafilter.com...]
[schillmania.com...]
Hope that helps.