Click to See Complete Forum and Search --> : onMouseOver to change cell color


haynbrian
07-02-2003, 10:55 AM
Hello all,

I'm interested in making my links so that when I mouseOver the link, the entire cell background color will change. I've set the 'background-color' attribute in CSS but that doesn't light up the entire cell like I would like it to, and I'm wondering if I can do it with JavaScript.

Anybody have any ideas?

Thanks,

Brian

pyro
07-02-2003, 11:06 AM
Try this:

<td onmouseover="this.style.backgroundColor='#ced6de';" onmouseout="this.style.backgroundColor='white';">testing</td>

haynbrian
07-10-2003, 02:21 PM
Pyro,

I'm sorry it took me so long to reply. I got it to work, thanks!

Brian

Jona
07-10-2003, 02:28 PM
Even though your question was already answered, if you want to create a more complex script for this, you might want to take a look at my tutorial (http://jona.t35.com/experiments/tableChildNodes_tutorial.html), which explains a lot of this in-depth.

[J]ona

pyro
07-10-2003, 04:23 PM
Glad it's working for you. You're welcome... :)