Jump to content

Table header & Link Colours


SharkBait

Recommended Posts

Okay, I'm trying to figure out what I am doing wrong here.

 

I want to change the colour of a table's header (<th></th>) using CSS. This is what I have, but Firebug is showing its invalid or its ignoring it. Firefox is using the default a:link properties instead.

 

<style>
.files { background-color: #36c; }
.files th a:link, .files th a:visited, .files th a:active { color:#fff; }
</style>

<table class="files">
<tr>
  <th><a href="#">Link 1</a></th>
  <th><a href="#">Link 2</a></th>
</tr>
<tr>
  <td>Stuff here</td>
  <td>Stuff here too</th>
</tr>
</table>

 

Does that not look right? Using Firefox with Firebug, it shows that its ignoring the .files portion of the style and using whatever the set a:link, a:visited, a:hover, a:active properties which makes the Link text the same colour as the background.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.