PDA

View Full Version : Set different link colors


dane001
03-11-2008, 05:07 PM
HI
Iím in the process of creating a new web site, my template contains different colors in different areas on the page. Some of my links are located on a blue background and some are on a white background. I set the page properties links to FFFFFF (link color and visited links to FFFFFF); the problem Iím having is that the links on the white background are not showing. Is there any way to change specific link color (for the white background)?
Thanks for your help.
E.D

davidj
03-11-2008, 05:25 PM
use css and define a class

dane001
03-11-2008, 06:26 PM
Thanks for the reply.
i forgot to mention that I'm running the site on an ASP server and it will prevent me running PHP script..
is there any other easy way to do it?
thanks

davidj
03-11-2008, 06:32 PM
css is not php

Rob_Che
03-12-2008, 04:41 PM
You can create more than one css 'style' and point the <div> to a specifice style sheet - is that what you meant DavidJ ?

Are you using css to style the links you have ?

davidj
03-12-2008, 05:36 PM
yes


<div class="style1">link1</div>
<div class="style2">link2</div>




.style1{

font-family: Geneva, Arial, Helvetica, sans-serif;
font-size: 10px;
color: #333333;

}


.style2{

font-family: Geneva, Arial, Helvetica, sans-serif;
font-size: 10px;
color: #555555;

}

edbr
03-13-2008, 02:07 AM
another way for the same effect is


.two a:link {color:#09c;font-size:14pt;
font-family:book antiqua,Trebuchet MS;
font-weight:normal;
text-decoration:none;}

.two a:visited {color:#09c;font-size:14pt;
font-family:book antiqua,Trebuchet MS;
font-weight:normal;
text-decoration:none;}

.two a hover{color:#FF0000;font-size:14pt;
font-family:book antiqua,Trebuchet MS;
font-weight:normal;
text-decoration:none;}
and where you want the link
<span class="two"><a href="your page.html">your different link </a></span>