Reputation: 1074
I have a simple table with two columns
<table>
<tr>
<td>aaaaaaa</td>
<td>bbbbbbb</td>
</tr>
<tr>
<td>aaaaaaa</td>
<td>bbbbbbb</td>
</tr>
</table>
tr:hover {
background: grey;
}
When I put the mouse pointer above the row, the background of the row changes to grey, but there is little space between the rows
How can I remove this little space to keep the whole row in grey?
Upvotes: 0
Views: 2481
Reputation: 1601
Use cellspacing="0" cellpadding="0"
in table tag, this will solve your problem.
Upvotes: 2
Reputation: 3841
Here's a Codepen http://codepen.io/noobskie/pen/WQvjBx
set your cell-spacing
to 0
for html5 just add this to your css
border-collapse: collapse
Upvotes: 1