www.webdeveloper.com
Results 1 to 3 of 3

Thread: CSS 'color' setting problem?

  1. #1
    Join Date
    Mar 2008
    Posts
    32

    Unhappy CSS 'color' setting problem?

    Hi,

    I am having a problem setting the text color for one of the sections of my design, the white box on the left hand side refuses to have #3c3c3c color text with out changing the rest of the text from #f7f7f7...

    i have spent the last 2 hours trying to figure it out using FireBug, but just can't get it...

    Any Help or Oppinions on the design are appreciated...

    Please find page at yabo.co.uk/layout.php, i can provide the source code in zip or rar compression if you ask...

    Thanks

    SpinnyKid

    P.S.

    This is an internal only site, and will only be used in FF3+, so you don't have to provide any IE or Safari workarounds, unless you wan't to...
    Last edited by spinnykid; 05-02-2010 at 07:52 PM. Reason: Forgot link to site...

  2. #2
    Join Date
    Jul 2009
    Posts
    184
    If you add this style below the .box style in your style sheet:
    Code:
    .box p:last-child {
    	color: #???;
    }
    It will color the text in the box below the line, and not the title text above the line.

    OR...

    I would suggest changing the first <p> tag to an <h?> tag to indicate that it is a heading. Then you can style the text a bit more logically, for example:
    Code:
    .box h3 {
    	color: #3c3c3c;
    }
    .box p {
    	color: #00f;
    }
    Would produce your grey heading with blue text below the line.

    Nice looking, easy to use design BTW!

  3. #3
    Join Date
    Mar 2008
    Posts
    32
    thanks westweb, i will be sure to try that out, thank you for the compliment on the design...

    the second part of the design makes more sense, i totally forgot about the h? tags, and will look for other areas in the design where they can be used....

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles