PDA

View Full Version : text sound rollover effect


dholt
01-21-2009, 06:54 PM
I have some small sound bites that I would like to incorporate into the navbar, so when a user mouse go's of the text it says something like "push that button"

I think this will require two templates the HEADER and the NAVBAR

BUT I was wondering if someone could explain how I could make this happen:rolleyes:

Save this in your includes folder with the js extension:


function soundOne() {
document.all.sound1.src =
"/sounds/button.au"}


using sounds/button.au as the media file.

And then add


OnMouseOver="soundOne()"


to your <a> tag, something like


<a class="nav" href="http://www.example.com/" title="Home" OnMouseOver="soundOne()">Home</a>


and add this to your <head> to add the JS file to your pages externally:


<script src="/includes/sounds.js"></script>
<bgsound id="sound1">


I found this some were but I can't get back to the site. anyway is there a way to make this work