Solved

Css text color

Posted on 2014-10-27
5
105 Views
Last Modified: 2014-10-27
I have this tag: <span style='color:blue; text-decoration: underline;'>.

It produces like in the attached; blue underline but text not blue.

Why is text not blue?

Thanks
not-blue.jpg
0
Comment
Question by:Richard Korts
  • 2
  • 2
5 Comments
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40406724
The something must be overriding it e.g. using !important

If you add !important to the color does it work?
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 40406749
If the page has load time scripting then it is quite possible that the style has been hijacked by whatever plugin or theme is scripting the element.

You can try inspecting the element, but if it is getting modified with jquery you may not see accurate results.

Cd&
0
 

Author Comment

by:Richard Korts
ID: 40406755
!important does not work; I suspect the other css colors the <a link> differently; I will try adding color to the <a>
0
 
LVL 58

Expert Comment

by:Gary
ID: 40406763
So there is an anchor tag in the span? Then it will have it's own color not inherited from the span but you could add an inherit

a {
color:inherit
}
0
 

Author Closing Comment

by:Richard Korts
ID: 40406767
Adding this worked: <a href='#' style='color: blue;'

Of course I realize I didn't mention these were links, but issue solved.
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

CSS3 Custom checkboxes This article shows how to style the checkbox form element using only CSS. Works in: Chrome, FF, Safari, Opera, IE9+ Uses modernizr.js to check for :checked pseudo class, falling back to plain old checkboxes (IE8 and bel…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…

707 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now