By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
432,086 Members | 1,919 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 432,086 IT Pros & Developers. It's quick & easy.

child selector not working on ie ?

P: n/a
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, positioning everything aligned left.

I'm familiar with http://w3development.de/css/hide_css_from_browsers/
I thought the ie child selector bug only occurred where there were no
spaces (parent>child) - I'd thought it worked when there were (parent >
child).
Apparently not - or am I missing something ?
http://services.ccagroup.co.uk/testform2.htm (&css) are identical apart
from the omission of ">".

Chris
Mar 2 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Chris Sharman wrote:
ie ignores the child selector, positioning everything aligned left.
Yes. IE doesn't support selectors introduced in CSS 2.
I thought the ie child selector bug only occurred where there were no
spaces (parent>child) - I'd thought it worked when there were (parent >
child).


I have a feeling that if there are spaces then it might treat it like a
descendent selector - but don't quote me on that.

I think Dean Edward's script will hack child selector support into IE.
Another option is:

foo bar { /* Set */ }
foo * bar { /* Reset to status before setting */ }

Mar 2 '06 #2

P: n/a
David Dorward wrote:
Chris Sharman wrote:
ie ignores the child selector, positioning everything aligned left.


Yes. IE doesn't support selectors introduced in CSS 2.


Ah. OK. http://w3development.de/css/hide_css_from_browsers/ could
probably do with clarifying then - it misled me.
I thought the ie child selector bug only occurred where there were no
spaces (parent>child) - I'd thought it worked when there were (parent >
child).


I have a feeling that if there are spaces then it might treat it like a
descendent selector - but don't quote me on that.


Doesn't seem to.
I can work around it - just need to be careful with precedence.

Thanks
Chris
Mar 3 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.