PDA

View Full Version : Underlined links problem


rstanberry
11-23-2007, 07:03 PM
I've only recently come back to the world of building websites and I have a problem remembering how to do a lot of stuff. I'm also now using Dreamweaver MX instead of good ol' frontpage, so there's been a period of adjustment.

I don't want links to automatically be underlined on my website: www.faucr.com (http://www.faucr.com)

I want the links on the sidebars of the page to only be underlined when they're being hovered over. I want the links in update posts to be underlined but I'd rather have to go the extra step and underline them than have that be the norm. I've tried adjusting my CSS but I can't find anything that will allow me to make a link not be underlined.

Any help?

edbr
11-24-2007, 04:53 AM
text-decoration:none;

rstanberry
11-24-2007, 07:24 AM
I've tried that. It doesn't work. I'm not sure why, it seems like it should, but I doesn't. I was hoping for some sort of style setting to put at the head of the code.

d a v e
11-24-2007, 07:51 AM
you need this in your style sheet

a:link {
font-family: Arial, sans-serif;
font-size: 16px;
font-style: normal;
line-height: normal;
color: #FFFFFF;
text-decoration: none;
}
a:visited {
font-family: Arial, sans-serif;
font-size: 16px;
font-style: normal;
line-height: normal;
color: #FFFFFF;
text-decoration: none;
}

a:hover, a:focus: a:active {
font-family: Arial, sans-serif;
font-size: 16px;
font-style: normal;
line-height: normal;
color: #FFFFFF;
text-decoration: none;
}

and change the visited,hover, focus (for keyboard users - using the tab key to navigate) and active states to your liking

instead of this

.links {
font-family: Arial;
font-size: 16px;
font-style: normal;
line-height: normal;
color: #FFFFFF;
text-decoration: none;
}

domedia
11-24-2007, 03:40 PM
text-decoration: none will work. Your implementation must be flawed.
See link in my signature for things to provide when asking a question of technical nature :)

rstanberry
11-26-2007, 11:20 PM
d a v e,

Thanks very much, pasting that change into my css document did the trick. I did have to edit it so that it didn't set a font size but it really did the trick. Thank you very much.

domedia,

No, though it's entirely possible that the my implementation was flawed, setting text-decoration: none did not work. Perhaps my old version of dreamweaver (it is MX remember) had something to do with it. But I will admit that I am new to this.

I'd also like to know specifically what I was supposed to be reading the rules for posting for so that I don't make the same mistake in the future.

domedia
11-27-2007, 01:40 PM
I'd also like to know specifically what I was supposed to be reading the rules for posting for so that I don't make the same mistake in the future.
http://www.dreamweaverclub.com/forum/showthread.php?t=23515
Not as much rules, as it is helping yourself getting help :)
Giving your code is of course the biggest thing you can do to make sure you're getting adequate help. Especially if you're given code and it does not work for you, just paste the code your post so we can see where you went wrong.
In this case 'text-decoration: none' works in all modern browsers, but unless applied to the right element (anchor tag) and it's pseudo elements (link, visited, hover etc), will not work on links.