Font Color Not Applying! Please Help!!

This is a discussion on "Font Color Not Applying! Please Help!!" within the Web Page Design section. This forum, and the thread "Font Color Not Applying! Please Help!! are both part of the Design Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices




Reply
 
LinkBack Thread Tools
  #1  
Old Apr 12th, 2007, 11:24
Junior Member
Join Date: Apr 2007
Location: England
Posts: 22
Thanks: 0
Thanked 0 Times in 0 Posts
Font Color Not Applying! Please Help!!

I have created a nav bar, and applied the colour white, but only the bullets have gone white, and the actual text for the links is still black:

Code: Select all
#nav2{
position:absolute;
top:199px;
left:810px;
color:#FFFFFF;
font-weight:bold;
font-family:sans-serif}

#nav2 li{
border-bottom:1px dotted #646464;
margin-bottom:0.3em;
color:#FFFFFF}
How do I fix this annoying little thing oh great css gurus??

Thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Apr 12th, 2007, 11:49
Elite Veteran
Join Date: Sep 2006
Location: Pink House
Posts: 3,946
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

If you have the text buttons linked, then you will have to create css for a:link, a:visited, a:hover, a:active.

Otherwise you won't see the changes.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old Apr 12th, 2007, 12:45
masonbarge's Avatar
Highly Reputable Member
Join Date: Jan 2006
Location: Atlanta GA
Posts: 631
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

It really helps to have a link (if the page is online) or at least the html code.

Try this: add a "#nav2 ul" style and designate the list items "#nav2 ul li".
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old Apr 13th, 2007, 04:32
Reputable Member
Join Date: Mar 2005
Location: Margaritaville (a state of mind somewhere between Inebriation and San Diego), CA
Posts: 245
Thanks: 6
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

Lchad is probably right - assuming you're using the LI's as links, you're inheriting the font color from the link style (probably defined in your body selector). A quick, easy way to verify this would be to use
Code: Select all
#nav2 a {
color:#fff;}
Note that you can do a lot of your link styling using the base "a" selector, but you'll need to follow it up with styling specific to each of the link states. Let me know if that's not clear and I'll post an example.

One other note: I find Firebug (runs as a Firefox add-on) indispensible for troubleshooting CSS issues. As you mouse over the code in the Firebug window, it highlights the element on the page and displays the associated CSS - including inherited properties. Makes it a whole lot easier to see what inherited properties are wreaking havoc on your intent!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old Apr 13th, 2007, 15:37
Elite Veteran
Join Date: Aug 2005
Location: That Place
Posts: 2,044
Blog Entries: 1
Thanks: 0
Thanked 37 Times in 37 Posts
Re: Font Color Not Applying! Please Help!!

#foo li a {} would be more appropriate or #foo ul li a {}

#foo li a {}
#foo li a:visited{}
#foo li a:hover {}

etc etc
__________________

Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old Apr 13th, 2007, 17:49
Reputable Member
Join Date: Mar 2005
Location: Margaritaville (a state of mind somewhere between Inebriation and San Diego), CA
Posts: 245
Thanks: 6
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

I'm curious as to why you say that? A link using an li is still a child of nav2, right? Why increase the size of the css file if you don't have to?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7  
Old Apr 13th, 2007, 19:57
Most Reputable Member
Join Date: May 2006
Location: North West, UK
Age: 22
Posts: 1,173
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

It's easier to Identify if it's laid out that way. And the increase in file size would be negligible except on extremely large sites.

Pete.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8  
Old Apr 13th, 2007, 23:13
Ryan Fait's Avatar
Elite Veteran
Join Date: May 2006
Location: Las Vegas
Posts: 3,787
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

I personally use a .nav a {}

Adding ul li in there doesn't do anything, and all the extra selectors can cause conflicts when something isn't defined quite as much. I keep it as simple as possible.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #9  
Old Apr 13th, 2007, 23:30
Most Reputable Member
Join Date: May 2006
Location: North West, UK
Age: 22
Posts: 1,173
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

I find it easier to identify selectors that way if I'm revisiting a sheet and I've never really had any conflicts yet. It doesn't really matter which way you do it, in my eyes, as long as you are consistent.

Pete.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #10  
Old Apr 13th, 2007, 23:59
Ryan Fait's Avatar
Elite Veteran
Join Date: May 2006
Location: Las Vegas
Posts: 3,787
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Font Color Not Applying! Please Help!!

Yep. Sometimes when I have a really large style sheet, I'll run into a situation where changing a few properties has no effect because later or earlier on in my style sheet I have a different selector order that's overriding what I'm trying to change. Highly frustrating sometimes!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
colour, css, font color

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
background-color kapyrossi Web Page Design 5 Jul 4th, 2007 15:53
Rollover behaviour applying to whole div-HELP tobymather Web Page Design 7 Apr 13th, 2007 23:52
Applying style to first para only Tino Web Page Design 6 Feb 28th, 2007 10:28
Dreamweaver Templates - applying to batch pages wheatus Web Page Design 0 Apr 15th, 2004 12:18


All times are GMT. The time now is 01:08.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42