Link colours


I'm making a template and I want different links to have different colours. I can do this when the link is fixed (always the same text i.e. clients website). But I also want green links in the regular text, but a blue link in a button. I have to be able to change the text and the link that's behind it. Now they are both green. I used this code:
a:link {
color: #99ac2a;
a:hover {...

Can I override the standard link colour in the button? I tried it like this, but it doesn't work.
a.knop:link {
color: #292f6d;
a.knop:hover {...

<td height="30" align="center" width="170" style="background-color:#F3F7D9;border-width:1px;border-style:solid;border-color:#E7E7E7;border-collapse:collapse; " ><a href="" class="knop" style="font-family:Verdana; font-size:12px; line-height:30px; text-decoration:none; color:#292f6d; margin-top:0px; margin-bottom:0px;"><strong><singleline label='knop'>Knop</singleline></strong></a></td>

Thanks for helping me

leinverheij, 2 years ago

I don't think you need the :link in your css.
Just put a.knop {

Join 150,000 companies around the world that use Campaign Monitor to run email marketing campaigns that deliver results for their business.

Get started for free