Jump to content

Changing color of an element


Bule
 Share

Recommended Posts

I'm trying (and have tried a few different ways) to change the anchor link (indicated by a comment) to a different color. I'm not having success. In my endeavors, I was even able to answer a question for someone else, but still can't make my own example work. :(

<!DOCTYPE HTML ><html>   <head>	  <title>Syntax Reference</title>	  <style>  		 body		 {		 background-color:#FEFAF2;		 color:black;		 }		 h1		 {		 color:#A0522D;		 }		 table		 {		 width:70%;		 }		 table, th, td		 {		 background-color:#FDF5E6;		 border-collapse:collapse;		 font-size:12px;		 border:1px solid #000000;		 }		 a.term{		 color:red;		 }	  </style>   </head>   <body>	  <h1>Syntax Reference</h1>	  <p>This page has a table.</p>	  <table>		 <thead>			<tr>			   <td colspan="2">				  <!--  Make this red  -->				  <a style="term" id="if">if </a>			   </td>			</tr>			<tr>			   <th>Arguments</th>			   <th>Result</th>			</tr>		 </thead>		 <tbody>			<tr>			   <td>Cond</td>			   <td>Pops data from stack (Cond) and executes following commands if true.</td>			</tr>		 </tbody>	  </table>   </body></html>

Any advice on what I"m doing wrong? I tried the following alternatives in my css: .term a {color:red}a .term {color:red} and a few others I don't recall right now. TIA

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...