Lance Qi
Lance Qi

Reputation: 13

CSS style my django table

picture of my table

I rendered my table with django table2 and above link how it looks like.

I style it with CSS like this:

thead {
    background-color: #4CAF50;
    font-color: white;
}

It looks like the background-color works and it shows green However the font-color did not turn white. Strangely it is purple/blue. Any idea why?

thanks in advance!

Upvotes: 1

Views: 1086

Answers (1)

ScientiaEtVeritas
ScientiaEtVeritas

Reputation: 5278

They are hyperlinks (a tag) for which the browser has default colors. You can set the color of hyperlinks like that:

For unvisited links

a:link {
    color: red;
}

Visited links

a:visited {
    color: green;
}

Hover over links

a:hover {
    color: hotpink;
}

Selected links

a:active {
    color: blue;
}

Or if you want for all the same color:

a {
 color:white;
}

If you also want to get rid of the underlines you can set the text-decoration property to none:

text-decoration:none;

Upvotes: 1

Related Questions