I have a table in html like:
<table>
<tr class="myClass">
<td>John</td>
<td>Smith</td>
</tr>
</table>
What I want is to change font color, background color and use a pointer when the user drives his mouse on the row, any point on the row. I am using below, but it is not working?
tr.myClass:hover
{
cursor: pointer;
color: #1d5987;
background:#F0F8FF;
}
The code below is working, but the changes are affecting the column the curser on instead all row.
tr.myClass:hover>td:hover
{
cursor: pointer;
color: #1d5987;
background:#F0F8FF;
}
How can I make it? Thanks
EDIT: Answers are not helping. I think my main problem is that when I click F12 when drive my cursor on the row, only the row the curser on is getting highlighted, but all the row should be get highlighted.