Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win


Problem removing underline in hyperlink in Firefox and IE8

Posted on 2009-04-05
Medium Priority
Last Modified: 2013-12-07
I´m having an annoying problem with removing underline from hyperlinks in Firfox and IE8.

I use this doctype: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
I use one style for the main links were I want all links to be underlined and another style for the menu were I don't wan't the links underlined.

It works fine in IE6 and IE7 but In other browser like IE8, Firefox, Opera and Goggle Chrome the links are always underline.  To get rid of the underlines I have to set text-decoration:none to the main stylw, which I don't wan't as I only wan't the menu to be without underlines.
My main style for the hyperlinks is like this:
A:visited {
	COLOR: #ED1E24; TEXT-DECORATION: underline	}
A {
	COLOR: #ED1E24; TEXT-DECORATION: underline}
A:hover {
	COLOR: #54554F; TEXT-DECORATION: underline;}
A:active {
	COLOR: #ED1E24; TEXT-DECORATION: underline}
The style for the menu is like this:
.Menu:visited {
	font-family: verdana;
	font-size: 11;
	color: #54554F;
	font-weight : bold;
	text-decoration : none;
.Menu {
	font-family: verdana;
	font-size: 11;
	color: #54554F;
	font-weight : bold;
	text-decoration : none;
.Menu:hover {
	font-family: verdana;
	font-size: 11;
	color: #ED1E24;
	font-weight : bold;
	text-decoration : underline;
.Menu:active {
	font-family: verdana;
	font-size: 11;
	color: #54554F;
	font-weight : bold;
	text-decoration : none;
Do you know how I can get rid of the underlines in the menu links without removing underline for all the website?

Open in new window

Question by:GDB08
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
LVL 43

Expert Comment

by:David S.
ID: 24073005
Please show us your markup. I can't tell which IE bug you've run into based on just those style rules.

Author Comment

ID: 24073103
I'm not sure what you mean by markup?
If I disable underline in the first style then it works in the second also.
LVL 43

Accepted Solution

David S. earned 750 total points
ID: 24073150
HTML is short for Hyper-Text Markup Language, so by "markup" I mean I need to see that section of your HTML code.

Also I should mention that the "A:visited" should come after the "A" rule, not before it. The same applies to the ".Menu" and ".Menu:visited" rules.

By the way, you don't need that many rules to set those styles.
LVL 13

Assisted Solution

qwerty021600 earned 750 total points
ID: 24074377
i also came across the same problem once,... infact I had to remove it from the main and give classes to all the links..
So i think you also have to do the same.

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Now-a-days, indirectly, postal services have been replaced by email services. Yes, whenever we hear the word "email" a lot of people only think of gmail. Some people still think that email and gmail are one and the same thing :-). Let's see some …
Bada platform is becoming more and more famous this days and people talking about same. Some friends included those who have bada OS mobile asked me "what is bada?"and "what its features?". That encouraged me to research and write this article. [st…
How to create a custom search shortcut to site-search Experts Exchange using Google in the Firefox browser. This eliminates the need to type out site:experts-exchange.com whenever you want to search the site. Launch your Bookmark Menu: Press 'Ctrl +…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question