What does it mean when styling is crossed out?

Posted on 2013-01-29
Last Modified: 2013-01-30
I've set text-decoration for links to none.  But I still see an underline.  Looking in Firebug, there is a second instance that overrides the first.  Is this why the underline is still there?  

firebugWhat does it mean when there is a second instance crossing out the first one?
Question by:brettr
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
LVL 10

Accepted Solution

deviprasadg earned 125 total points
ID: 38833933
CSS properties are also crossed out if they are overwritten by another rule. This helps you determine specificity problems, as well as seeing why certain styles are not applying the way you had hoped.

Please refer:

Author Comment

ID: 38834013
I can disable the second instance but don't see any change.  The underline is still there on links.  What does this mean?

LVL 83

Expert Comment

by:Dave Baldwin
ID: 38834033
That probably means you haven't turned it off.  Underlining links is the default in most browsers.  See here:
A common way of killing the underline is using ...
a:link {text-decoration:none;}

Open in new window

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.


Author Comment

ID: 38834050
Yes - I have that but it has no effect.
LVL 83

Expert Comment

by:Dave Baldwin
ID: 38834060
Then you have it somewhere else also that is overwriting that one.  Add...
a {text-decoration:none;}
a:link {text-decoration:none;}
a:hover {text-decoration:none;}

Open in new window


Author Comment

ID: 38834067
I have all the above already.  How do I track down the override?

From the 2nd screenshot, you can see I have disabled the overrides.  The first instance of #footer a is all that is left at that point.
LVL 16

Assisted Solution

HagayMandel earned 125 total points
ID: 38834069
These links are not affected by your CSS, and that means that either they are not positioned within an element with an id of "footer", or somewhere in your CSS file, on a higher level element, there's a CSS rule that contains the '!important' instruction.
The best you can do, is provide a link or a complete code (HTML & CSS)
LVL 83

Assisted Solution

by:Dave Baldwin
Dave Baldwin earned 125 total points
ID: 38834083
Clearly you don't have all that and the code you posted ONLY affects the #footer and does not cover 'text-decoration' which is needed for 'underline'.  'border' is not 'underline'.
LVL 22

Assisted Solution

by:Kim Walker
Kim Walker earned 125 total points
ID: 38835088
What we can't see in the screen capture you've posted is the location of the styles that are taking precedence. To the far right of these styles is the name of the css file and the line within that file where these styles are located. This is cut off of the screen capture above. If these two styles are not in the same css file, either you have another css file being loaded afterward or you have a style definition embedded within your html. In either case, neither of these styles controls the underline outside of Firefox. Both of them deactivate a Firefox specific underline.

The topmost style in the Firebug list is the style with precedence. It can override any of the styles listed beneath it. So disabling the second instance does nothing when the same styles are included in the top instance. In this case, those styles in the second instance are already deactivated (overridden) by the top instance.

Even though the underline should be deactivated in Firefox, the link element (a tag) is being adorned with a bottom border in the second instance. The border style is not included in the top instance so it remains active. This bottom border would look very much like an underline. If the underline were also present, it would appear as a double underline since the border should appear lower than the underline.

Try disabling in Firebug the bottom border styles in the second instance. What looks like an underline should disappear. If it doesn't, look below these two instances for the "text-decoration" attributes (NOT "-moz-text-decoration"). If there are no instances of text-decoration, the default underline for a tags is still active. Most likely, though, you are seeing the bottom border instead of an underline.

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

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

Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
When the s#!t hits the fan, you don’t have time to look up who’s on call, draft emails, call collaborators, or send text messages. An instant chat window is definitely the way to go, especially one like HipChat. HipChat is a true business app. An…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

734 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