[css-d] Inheritence Problem
I am using the Konqueror 3.5.6 browser on Kubuntu Linux. I need text displayed as white against a dark background. My initial code applied the color: property to the paragraph. This does not work: p style=text-align: center; color: white; h3Title of Page/h3/p The solution was to place the color: inside the h3 tag. p style=text-align: center; color: white; h3 style=color: white;Title of Page/h3/p Everything I've read on the 'net says that the h3 should inherit color: white; from the parent, p, tag. Both h3 and p are inline elements. What's happening? Thanks, Bob __ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Re: [css-d] Inheritence Problem
I believe the reason for this is that conquerer sees an error with your HTML. The paragraph tag is one of those block level elements that can only contain inline level elements. H3 is a block level element. I found this link, which seems to have good information about why this is the case. http://www.autisticcuckoo.net/archive.php?id=2005/01/11/block-vs-inline- 1 In your example, there really is no need to have the following: ph3text/h3/p It can be replaced with: h3text/h3 This will remove the issue and tidy up your code. __ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Re: [css-d] Inheritence Problem
I have never seen an h3 tag nested inside a p tag. Perhaps therein lies your problem. Usually p tags inherit from h tags because headers are above paragraph levels. Robert Tilley wrote: I am using the Konqueror 3.5.6 browser on Kubuntu Linux. I need text displayed as white against a dark background. My initial code applied the color: property to the paragraph. This does not work: p style=text-align: center; color: white; h3Title of Page/h3/p The solution was to place the color: inside the h3 tag. p style=text-align: center; color: white; h3 style=color: white;Title of Page/h3/p Everything I've read on the 'net says that the h3 should inherit color: white; from the parent, p, tag. Both h3 and p are inline elements. What's happening? Thanks, Bob __ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/ __ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Re: [css-d] Inheritence Problem
- Original Message - From: Conjurer [EMAIL PROTECTED] Date: Thursday, May 17, 2007 6:59 am Subject: Re: [css-d] Inheritence Problem To: Robert Tilley [EMAIL PROTECTED], Css-Discussion Group css-d@lists.css-discuss.org I have never seen an h3 tag nested inside a p tag. Perhaps therein lies your problem. Usually p tags inherit from h tags because headers are above paragraph levels. Robert Tilley wrote: I am using the Konqueror 3.5.6 browser on Kubuntu Linux. I need text displayed as white against a dark background. My initial code applied the color: property to the paragraph. This does not work: p style=text-align: center; color: white; h3Title of Page/h3/p The solution was to place the color: inside the h3 tag. p style=text-align: center; color: white; h3 style=color: white;Title of Page/h3/p Everything I've read on the 'net says that the h3 should inherit color: white; from the parent, p, tag. Both h3 and p are inline elements. What's happening? Thanks, Bob Paragraphs and headings don't inherit anything from each other - they're unique, separate things. They both inherit from body and html, though. David [EMAIL PROTECTED] authenticity, honesty, community __ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7 information -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/