I am not very good at writing javascript code so I am hoping that someone on this forum can help. Here is my situation.
On the Home page of my web site I have have the following code to send the user from the Home page to my Intro page:

<p><a href="intro.htm" > Enter </a></p>

Is it possible, using javascript, to also add a sound effect to this action? I have a sound effect in a "wave" file that I would like to hear when I click on "Enter".

As it is now I have the following in web site root folder:
-a javascript folder called "jsscripts"
-a wave file called "meow.wav"

I want to save the above javascript in my "jsscripts" folder by the file name "meow.js" and have this call my wave file when I click on "Enter".

What changes do I have to make to the above javascript and to my own current html to make my sound effect work? I have played around with the "onClick" function but am still missing something.

Hopefully I have provided you with enough information.
Thanks :)

ddadmin

11-02-2009, 08:33 PM

Firstly, you should be aware this script only works in IE. To get it to activate onclick, you should be able to do this just by changing the keyword onmouseover inside the HTML to onclick instead, for example: