Forum Moderators: open

Message Too Old, No Replies

Font Color

         

smilinjack

1:37 pm on Nov 19, 2004 (gmt 0)

10+ Year Member



Greetings Friends!
How can I set the color below so all the links are the same without having to put the "Font Color=" script on every link?

<a href="http://www.exmaple.com/"><font color="black">Example1</A>
<a href="http://www.example.net/"><font color="black">Example2</A>
<a href="http://www.example.org/"><font color="black">Example3</A>

Thanks,
Jack

[edited by: tedster at 7:57 pm (utc) on Nov. 19, 2004]

Alternative Future

1:45 pm on Nov 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi smilinjack,

If you paste this between your <head>here</head> tags you can have the style rule apply to all your anchor tags.
If you create an external style sheet and reference it in your pages then the effect shall be throughout your pages/site.

<style type="text/css">
a{
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
font-weight: normal;
color: black;
text-decoration: none
}
a:visited{
color: green
}
a:hover{
color: red;
text-decoration: underline
}
a:active{
color: blue
}
</style>

HTH,

-George

Matt Probert

4:27 pm on Nov 19, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Just one little thing, it's not advisable to specify absolute font sizes. Either leave it to the browser/user or use relative sizes.

Matt

PatrickKerby

7:33 pm on Nov 20, 2004 (gmt 0)

10+ Year Member



clip from Zeldman's 'Designing with Web Standards':

"Unlike relative sizes based on em, pixel-based sizes are 99.9% dependable across all browsers and platforms."

smilinjack

7:50 pm on Nov 20, 2004 (gmt 0)

10+ Year Member



Thanks to all for your help!

jawfish

7:54 pm on Nov 20, 2004 (gmt 0)



I agree, I have experienced great results with CSS absolute sizes.