Click to See Complete Forum and Search --> : Maintaining color of link
Ninel
03-11-2003, 03:15 PM
You know how when you first load a page a link is one color, but then when you click on it the color changes.
Is there any way to keep the link a particular color no matter how many times it was clicked?
DaveSW
03-11-2003, 03:59 PM
Use a font tag... If you're using a graphical editor, just highlight the text and specify a font colour. Make sure the font tag is inside the A tag.
You could also do this with css, but if you haven't got many links then this way is easiest
dave
DaveSW
03-11-2003, 04:15 PM
The CSS ways include
(after your title tag but in the head tag)
<STYLE TYPE="text/css">
A {
color: blue;
}
</STYLE>
or... (more complex)
<STYLE TYPE="text/css">
A:link {
text-decoration: none;
font-weight: bold;
color: #C00;
background: #FFC;
}
A:visited {
text-decoration: none;
font-weight: bold;
color: #C00;
background: #FFC;
}
A:active {
text-decoration: none;
font-weight: bold;
color: #C00;
background: #FFC;
}
A:hover {
text-decoration: none;
color: #CCC;
background: #FF0;
}
A.offsite {
text-decoration: none;
font-weight: normal;
color: #C00;
background: #FFC;
}
</STYLE>
does this help?
dave
khaki
03-11-2003, 04:34 PM
Hi Dave...
what's offsite?
(snuck a new one in on me. wink)
Thanks...
k
DaveSW
03-11-2003, 04:54 PM
Well ummm... confession is good for the soul and all that so... I'm not absolutely certain either, but i think it's if the link goes to a different web site, using a different window. I just copied it out of a W3 style sheet...
Dave
a.offsite checks for links that will be on a different domain than your site. Basically, you could use it to let visitors know that they will be leaving your site by clicking the link.
khaki
03-11-2003, 05:44 PM
Well Dave... Sod is always waitin' around the corner, isn't he? (lol)
Your honesty is admirable. Thanks (it sure beats gettin' the shine-on).
Pyro... I'm so sick of your know everything BS (LOL!!!!!!!).
Now go learn yourself some ASP and really become helpful! (wink).
Never a dull moment around here.
Thanks for keepin' it real guys!
thinking that "offsite" is over-rated...
k
Originally posted by khaki
Pyro... I'm so sick of your know everything BS (LOL!!!!!!!)....lol :D You are too funny, Khaki...