Quick web design question
Author
Discussion

moleamol

Original Poster:

15,887 posts

293 months

Friday 10th March 2006
quotequote all
I have an image as a link and what I would like to do is change it so that when you mousover the image changes and a sound is played. I'm fairly sure it's easy to do but google takes too much trawling for stuff like this.

Cheers.

zoidberg

8,883 posts

312 months

Friday 10th March 2006
quotequote all
You could try to use a javascript:mouseover event.

This www.w3schools.com is an excellent resource.

...or here www.javascripter.net/faq/onmouseo.htm

>> Edited by zoidberg on Friday 10th March 09:51

moleamol

Original Poster:

15,887 posts

293 months

Friday 10th March 2006
quotequote all
Will that work on a page using .css and .php? The image is in a header so I suppose it should do by just putting it in the header.

JoolzB

3,549 posts

279 months

Friday 10th March 2006
quotequote all
Javascript works independantly of css and php on the client browser so that shouldn't be a prob, the mouseover stuff is pretty simple using javascript but can be done using CSS but that's a bit limited. Really not too sure on the sound thing though, you can embed music etc in a web page that get's played using the default player on the browser machine, how you kick that sound off I'd guess would have to be a javascript bit of code.

_dobbo_

14,619 posts

278 months

Friday 10th March 2006
quotequote all
Don't do it!!!!

Just kidding, do what you want!

www.albinoblacksheep.com/tutorial/mouseoversound