Loading table for all rows, not just any other

I am using Bootstrap 3 and applying table-striped table-hover

tables to my class.

However, I changed the default bar color to green. So for my columns I have green - white - green - white.

Now that I find myself, white turns to blue. It is perfectly. But when I hover over green, it stays green.

How can I find each line, hover over #ecf3f8

?

I've tried this to no avail:

.table-hover tbody tr.odd:hover td, .table-hover tbody tr.odd:hover th {
  background-color: #ecf3f8;
}

      

+3


source to share


3 answers


Sounds like a specificity problem. Try the following:



.table-striped.table-hover>tbody>tr:hover>td, 
.table-striped.table-hover>tbody>tr:hover>th {
  background-color: #ecf3f8;
}

      

+7


source


try this:

.table-hover tbody tr:hover td {
  background: #ecf3f8 !important;
}

      



edit: also try this:

.table-hover > tbody > tr:hover > td {
  background: #ecf3f8 !important;
}

      

+2


source


Try the following:

.table-striped tbody tr:hover td,
.table-striped tbody tr:hover th {
    background-color: #ecf3f8
}

      

You can try it here: http://www.bootply.com/2Gp7XHJ9jV

Source: https://github.com/twbs/bootstrap/issues/3223#issuecomment-5735608

+2


source







All Articles