Jump to content

onMouseOver Events


angelodev

Recommended Posts

hi there, i have a piece of code that look like this:

 

<td style= "something.... " onMouseOver = "changestyle" onMouseOut = "changestyle">

 

Right now, i have to change the style of the page adding a CSS files, just for make clear the page code.

Is there a solution for insert into the CSS also the two style changed by the onMouseOver/out events?

And how can i recall from the TML page?

Link to comment
https://forums.phpfreaks.com/topic/50214-onmouseover-events/
Share on other sites

I ave to change te cells background color where the mouse come over.

For make more clear the code , i'd like to use CSS. If I change the class dinamically with Javascritp, the background will change or i have to refresh thw browser?

 

As fenway suggests, simply changing your class will let you do what you're after. If you generate a class in your CSS something like "td.hover", you could just apply it like so:

<td onmouseover="this.className='hover';" onmouseout="this.className='';"></td>

Link to comment
https://forums.phpfreaks.com/topic/50214-onmouseover-events/#findComment-247380
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.