View Full Version : How to remove anchor text underline?
ViciousSummer
Nov 9th 2004, 9:53 pm
Can anyone tell me how to remove the line that appears under hot linked words (or anchor text)? I edit my website in Dreamweaver and sometimes the line shows up and sometimes it doesn't, so I would like to know how to change the code. Does anyone here know the code for that? More importantly, does anyone know what the heck I'm even talking about... ;) ...
ResaleBroker
Nov 9th 2004, 9:55 pm
Are you using CSS?
chachi
Nov 9th 2004, 10:01 pm
assuming you are using css or style sheets check this out. You will want to set the text-decoration attribute for your anchor elements. http://www.w3schools.com/css/pr_text_text-decoration.asp
Something like this:
a:link {color: #00ff00;}
a:active {color: #0000ff;}
a:visited {color: #ffffff;}
a:hover {color: #000000; text-decoration: none; }
would remove the line when the mouse pointer hovers over the text.
ViciousSummer
Nov 9th 2004, 10:01 pm
Oops...Found it with a lil ol' Google search for "Code to remove anchor text underline". If any one else cares (and uses Dreamweaver), this was very helpful:
http://www.macromedia.com/support/dreamweaver/ts/documents/no_underline.htm
Thanks anyways!!
:D
digitalje5u5
Nov 10th 2004, 7:51 am
Useful information. Thanks.
jayL
Dec 6th 2006, 10:15 pm
I was curious if this has worked with the others. Anyone ever tried removing the underline from adsense text links?
Would appreciate for a code in WP
Nima
Dec 6th 2006, 10:43 pm
.Link {
font-family:Verdana, Arial, Helvetica, sans-serif;
font-size:12px;
font-weight: bold;
}
a.Link:link { text-decoration:none; color:#3C5AA2;}
a.Link:visited{ text-decoration:none; color:#3C5AA2;}
a.Link:hover{ text-decoration:none; color:#FFA74F;}
jayL
Dec 6th 2006, 11:19 pm
Nima : not sure if I got the css code incorrectly but have you tried this and worked? Got a link?
kk5st
Dec 7th 2006, 1:16 pm
<snip>
Something like this:
a:link {color: #00ff00;}
a:active {color: #0000ff;}
a:visited {color: #ffffff;}
a:hover {color: #000000; text-decoration: none; }
would remove the line when the mouse pointer hovers over the text.
If you want this to act as expected, the order of the selectors is important. Put the selectors in this order:
a:link {}
a:visited {} /*:link and :visited are mutually exclusive, so precedence doesn't
matter, but for consistency, act as if it does*/
a:focus {} /*not supported by IE, so is seldom used*/
a:hover {}
a:active {}
A study of selector precedence rules will make the reasons obvious.
cheers,
gary
Nima
Dec 7th 2006, 2:39 pm
I dont think the order is important.
I'm using that exact CSS on blacksburgpoker.com
My css file is in the root directory and called style.css
All the links (in the content area) use the above Link format.
Cheers,
kk5st
Dec 8th 2006, 1:54 am
I dont think the order is important.
<snip>
Then, you're wrong.
gary
Nima
Dec 8th 2006, 2:38 am
I didn't know that it matters (i guess i was luckily using the right format)
What are link focus and active?
kk5st
Dec 8th 2006, 4:37 pm
See http://www.w3.org/TR/CSS21/selector.html#q15
cheers,
gary
MTbiker
Dec 9th 2006, 2:52 pm
Anyone ever tried removing the underline from adsense text links?
Well, Adsense ads have their own style sheet if you are interested in looking at their styles. But it's against terms to make any changes to the ad display.
parusa619
Dec 9th 2006, 2:54 pm
Can anyone tell me how to remove the line that appears under hot linked words (or anchor text)? I edit my website in Dreamweaver and sometimes the line shows up and sometimes it doesn't, so I would like to know how to change the code. Does anyone here know the code for that? More importantly, does anyone know what the heck I'm even talking about... ;) ...
a {
text-decoration:none;
}
sorry for a very delayed advice
vBulletin® v3.6.8, Copyright ©2000-2008, Jelsoft Enterprises Ltd.