473,385 Members | 1,325 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Child selectors? I dont get it :(

I tried everything. I even tested it in combination with opera and mozilla.
(I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
</style>
</head>
<body>
<p>
hello
<span>why isnt this blue? </span>
hello
</p>
</body>
</html>
Thank you,
Tom
Jul 20 '05 #1
18 2088
"news.pandora.be" <tm***@hotmail.com> wrote:
I tried everything. I even tested it in combination with opera and mozilla.
(I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
</style>
</head>
<body>
<p>
hello
<span>why isnt this blue? </span>
hello
</p>
</body>
</html>


Works here (Opera), won't work in IE as it doesn't support child
selectors.

--
Spartanicus
Jul 20 '05 #2
Els


Spartanicus wrote:
"news.pandora.be" <tm***@hotmail.com> wrote:

I tried everything. I even tested it in combination with opera and mozilla.
(I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
</style>
</head>
<body>
<p>
hello
<span>why isnt this blue? </span>
hello
</p>
</body>
</html>

Works here (Opera), won't work in IE as it doesn't support child
selectors.


And if you were using it on purpose to hide it from IE, than
avoid the spaces around >, for IE5.0 will apply the style if
you leave spaces.
--
Els

Mente humana é como pára-quedas; funciona melhor aberta.

Jul 20 '05 #3
On Sun, 22 Feb 2004 06:12:41 GMT, "news.pandora.be" <tm***@hotmail.com>
wrote:
I tried everything. I even tested it in combination with opera and mozilla.
(I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
</style>
</head>
<body>
<p>
hello
<span>why isnt this blue? </span>
hello
</p>
</body>
</html>


What version of Opera did you test? It's blue in Opera 6.05 and 7.23.
IE doesn't understand child selectors though. They've only been around
for about 6 years, and Microsoft can't react that fast.

--
Stephen Poley

http://www.xs4all.nl/~sbpoley/webmatters/
Jul 20 '05 #4
Stephen Poley wrote:
On Sun, 22 Feb 2004 06:12:41 GMT, "news.pandora.be" <tm***@hotmail.com>
wrote:

I tried everything. I even tested it in combination with opera and mozilla.
(I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
^
What version of Opera did you test? It's blue in Opera 6.05 and 7.23.
IE doesn't understand child selectors though. They've only been around
for about 6 years, and Microsoft can't react that fast.


Could it be it's just the ';' thats missing? (not tested)

--

Barbara

http://home.wanadoo.nl/b.de.zoete/html/weblog.html
http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html

Jul 20 '05 #5
Els wrote:

And if you were using it on purpose to hide it from IE, than avoid the
spaces around >, for IE5.0 will apply the style if you leave spaces.


Really? I never knew this. Now why on earth die M$ mess this up in the
release of IE6.0?

--

Barbara

http://home.wanadoo.nl/b.de.zoete/html/weblog.html
http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html

Jul 20 '05 #6
Els


Barbara de Zoete wrote:
Els wrote:

And if you were using it on purpose to hide it from IE, than avoid the
spaces around >, for IE5.0 will apply the style if you leave spaces.

Really? I never knew this. Now why on earth die M$ mess this up in the
release of IE6.0?


No, 5.5 already :-)
I think that IE5.0 doesn't really understand it, but fails
to see the >.
Then 5.5 saw it, but doesn't understand so doesn't apply,
idem for 6.0.
But that's just my thinking, as I'm not sure if IE 5.0
really gets the difference between just the child or another
descendant.
--
Els

Mente humana é como pára-quedas; funciona melhor aberta.

Jul 20 '05 #7
In article Barbara de Zoete wrote:
Els wrote:

And if you were using it on purpose to hide it from IE, than avoid the
spaces around >, for IE5.0 will apply the style if you leave spaces.


Really? I never knew this. Now why on earth die M$ mess this up in the
release of IE6.0?


No, IE5 will interpret "foo > bar" like "foo bar" that is incorrect too.

--
Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
Saapi lähettää meiliä, jos aihe ei liity ryhmään, tai on yksityinen
tjsp., mutta älä lähetä samaa viestiä meilitse ja ryhmään.

Jul 20 '05 #8
On Sun, 22 Feb 2004, Barbara de Zoete wrote:
Now why on earth [did] M$ mess this up


If we could answer *that* kind of question, we wouldn't be here on
usenet, I suspect. SCNR.
Jul 20 '05 #9
Lauri Raittila wrote:
Els wrote:
And if you were using it on purpose to hide it from IE, than
avoid the spaces around >, for IE5.0 will apply the style if you
leave spaces.


No, IE5 will interpret "foo > bar" like "foo bar" that is incorrect
too.


IE5/*Win* will interpret foo > bar as "foo bar"...

--
Brian (remove "invalid-remove" to email me)
http://www.tsmchughs.com/
Jul 20 '05 #10
It seems "news.pandora.be" wrote in
comp.infosystems.www.authoring.stylesheets:
(I use IE 6 mostly)

Please tell me what is wrong


Some questions answer themselves. :-)

Seriously, IE has really dreadful CSS support. Child selectors don't
work at all, for instance.
This is one of the big frustrations about writing for the Web. There
is often a simple, straightforward, standard way to do something;
but because stoopid Microsoft doesn't support it we have to choose
between doing it a different (complex, obfuscated) way or having it
work only for the savvy minority of visitors.

--
Stan Brown, Oak Road Systems, Cortland County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2 spec: http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator: http://jigsaw.w3.org/css-validator/
Jul 20 '05 #11
It seems "Barbara de Zoete" wrote in
comp.infosystems.www.authoring.stylesheets:
On Sun, 22 Feb 2004 06:12:41 GMT, "news.pandora.be" <tm***@hotmail.com>
wrote:
p > span { background-color: blue }

^
Could it be it's just the ';' thats missing? (not tested)


The semicolon is a separator, not a terminator. You don't need it
after the last property inside braces.

The real problem is much more straightforward (and annoying):
Microsoft simply doesn't support some standard selector forms
including this one.

http://www.blooberry.com/indexdot/cs...rs/element.htm

--
Stan Brown, Oak Road Systems, Cortland County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2 spec: http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator: http://jigsaw.w3.org/css-validator/
Jul 20 '05 #12
Stan Brown wrote:
(I use IE 6 mostly)

Please tell me what is wrong


Some questions answer themselves. :-)

Seriously, IE has really dreadful CSS support. Child selectors don't
work at all, for instance.


Can you blame anyone for using IE6 ? I mean what could we do ?
I really tried Netscape, which I couldn't believe it's free, but it has
drawbacks anacceptable for me :(

it has a horrible fullscreen mode, which it happens I use often to read
docs (it locks my autohide taskbar, the fullscreen is not really *full*
screen and it has no automenus and toolbar) and it has his own Favourites
(or bookmarks). Why doesn't it get also the Windows Explorer favourites ?

Sorry, I know this is off-topic
Jul 20 '05 #13
Stan Brown wrote:
(I use IE 6 mostly)

Please tell me what is wrong


Some questions answer themselves. :-)

Seriously, IE has really dreadful CSS support. Child selectors don't
work at all, for instance.


Can you blame anyone for using IE6 ? I mean what could we do ?
I really tried Netscape, which I couldn't believe it's free, but it has
drawbacks anacceptable for me :(

it has a horrible fullscreen mode, which it happens I use often to read
docs (it locks my autohide taskbar, the fullscreen is not really *full*
screen and it has no automenus and toolbar) and it has his own Favourites
(or bookmarks). Why doesn't it get also the Windows Explorer favourites ?

Sorry, I know this is off-topic
--
Thank you
Timothy Madden
---------------------------
And I don't wanna miss a thing
Jul 20 '05 #14
Timothy Madden wrote:

Can you blame anyone for using IE6 ?
Blame? no. But I wouldnt' recommend it.
Sorry, I know this is off-topic


Yes, it is. You might try asking about such things in a Netscape group.
I would have emailed you with more about Netscape, but I cannot figure
out if your email address is real or not. It looks fake. (If you want to
the response, email me, but remove "invalid" from the end of my email
address.)

--
Brian (remove "invalid" from my address to email me)
http://www.tsmchughs.com/
Jul 20 '05 #15
Thx for all the replies guys. It seems this is a nice usenet group :)

IE just doesnt support child selectors. It's a shame that MS doenst make
this work.

I recommend Opera cause it has good css support and I use IE only if the
site doesnt support opera.
These sites are mostly owned by MS. Probably no coincidence.

Its free if you can live with the banner. Defenitly worth a try!
"news.pandora.be" <tm***@hotmail.com> wrote in message
news:tL******************@phobos.telenet-ops.be...
I tried everything. I even tested it in combination with opera and mozilla. (I use IE 6 mostly)
It's reduced to the simple example below.

Please tell me what is wrong with my understaning of child selectors! I
realy dont know :(

<html>
<head>
<style>
p > span { background-color: blue }
</style>
</head>
<body>
<p>
hello
<span>why isnt this blue? </span>
hello
</p>
</body>
</html>
Thank you,
Tom

Jul 20 '05 #16
How am I supposed to post my replies in a newsgroup?:
http://allmyfaqs.com/faq.pl?How_to_post

Tom Pester wrote:

IE just doesnt support child selectors.
IE/*Win* doesn't support child selectors, you mean.
It's a shame that MS doenst make this work.
A shame, yes. But shoddy css support is the least of its sins.
I recommend Opera cause it has good css support
[...]
Its free if you can live with the banner. Defenitly worth a try!
You're preaching to the choir.
and I use IE only if the site doesnt support opera.
These sites are mostly owned by MS. Probably no coincidence.


That's what faked referrer headers are for.

--
Brian (remove "invalid" from my address to email me)
http://www.tsmchughs.com/
Jul 20 '05 #17

"Brian" <us*****@julietremblay.com.invalid> wrote in message
news:koa_b.103162$uV3.584881@attbi_s51...
How am I supposed to post my replies in a newsgroup?:
http://allmyfaqs.com/faq.pl?How_to_post

Tom Pester wrote:

IE just doesnt support child selectors.
IE/*Win* doesn't support child selectors, you mean.


So the mac version supports it? That doesnt help much :s
It's a shame that MS doenst make this work.


A shame, yes. But shoddy css support is the least of its sins.
I recommend Opera cause it has good css support
> [...]
> Its free if you can live with the banner. Defenitly worth a try!


You're preaching to the choir.
and I use IE only if the site doesnt support opera.
These sites are mostly owned by MS. Probably no coincidence.


That's what faked referrer headers are for.


I think you mean faking your "user agent"

--
Brian (remove "invalid" from my address to email me)
http://www.tsmchughs.com/

Jul 20 '05 #18
Tom Pester wrote:
and I use IE only if the site doesnt support opera. These sites
are mostly owned by MS. Probably no coincidence.


That's what faked referrer headers are for.


I think you mean faking your "user agent"


Yep.

--
Brian (remove "invalid" from my address to email me)
http://www.tsmchughs.com/
Jul 20 '05 #19

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Tony Benham | last post by:
I have been getting to grips with css recently (very slowly), and one area I have a problem is when to use class selectors or id selectors. Are there any guidelines when to use each type ? The key...
6
by: Veerle | last post by:
Hi, Somewhere in my html page, I have the following code: <div id="main-body"> <h2>Header text</h2> <p>Some other text ...</p> ..... <h2>Another header text</h2> <p>Some more other text...
1
by: news.pandora.be | last post by:
I tried everything. I even tested it in combination with opera and mozilla. (I use IE 6 mostly) It's reduced to the simple example below. Please tell me what is wrong with my understaning of...
4
by: Harlan Messinger | last post by:
At http://www.gavelcade.com/tests/partial-child-recognition.html is an illustration of an apparent inconsistency in the way the child selection operator > is handled with respect to tables, rows,...
19
by: Thomas Mlynarczyk | last post by:
Hello, The following gives different results in IE and "Non-IE" browsers: <div style="background-color: green; width: 200px"> <div style="margin-top: 20px; background-color: red"> Hello...
5
by: PAUL | last post by:
Hello, I have 2 tables with a relationship set up in the dataset with vb ..net. I add a new record to the parent table then edit an existing child record to have the new parent ID. However when I...
2
by: Chris Sharman | last post by:
See http://services.ccagroup.co.uk/testform.htm Looks as intended in firefox, is valid (bulk of inputs centred in a div occupying the left half of the page). ie ignores the child selector,...
9
by: Jeff | last post by:
Does IE7 support attribute and child selectors? Jeff
7
by: Dan | last post by:
Hi, IE 7 does not seem to like child selectors for lists. I couldn't find anything addressing this with google search. Example of problem-- If I want to apply the color red to all ordered list...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.