[thelist] tying events and styles together in JS?
Joshua Olson
joshua at waetech.com
Wed Feb 19 15:27:08 CST 2003
----- Original Message -----
From: "Tom Dell'Aringa" <pixelmech at yahoo.com>
Sent: Wednesday, February 19, 2003 11:14 AM
> <tr onmouseover="this.className='on';"
> onmouseout="this.className='off';" class="trHighLight">Stuff</tr>
Tom,
You could do something similar for by putting the handler in the table. So
long as the cellspacing is 0 the event is guaranteed to be fired from the
TD. For ie you would do something like this:
<table
onmouseover="event.srcElement.parentNode.className = 'on';"
onmouseout="event.srcElement.parentNode.className = 'off';">
The model is different for different browsers, so watch out. But, if the
platform is IE, then the above code may work for you.
-joshua
More information about the thelist
mailing list