BubikolRamios
09-15-2011, 04:48 PM
p > input {
float: left;
height: 16px;
left: 0;
margin: 0;
opacity: 0;
padding: 0;
position: absolute;
width: 16px;
}
what does > stands for ?
if I look at html, means same as without >
<p>
<input id="male" type="radio" name="gender" value="male">
<label for="male">Male</label>
</p>
?
teedoff
09-15-2011, 05:02 PM
Typo in their css?? Is this your page?
BubikolRamios
09-15-2011, 05:33 PM
Nope, not mine.
src.: http://www.thecssninja.com/demo/css_custom-forms/
Does not look like typo, the > is all over the css.
Inigoesdr
09-15-2011, 05:42 PM
It means immediate children.
This would match:
<p>
<input>
</p>
This would not:
<p>
<div>
<input>
</div>
</p>
BubikolRamios
09-15-2011, 05:50 PM
<p>
<div>
<input>
</div>
</p>
so you are saying that:
p input
{
..
}
would affect upper html, that is all inputs inside p regardless of depth & elements inbetween ?
or mybe:
p > input
would affect only first of those inputs ?
<p>
<input>
<input>
<input>
</p>
alykins
09-15-2011, 06:16 PM
I am pretty sure it would affect all three of those input because they are all direct children of the p
reference (http://www.w3.org/TR/CSS2/selector.html#child-selectors)
Inigoesdr
09-15-2011, 10:20 PM
so you are saying that:
p input
{
..
}
would affect upper html, that is all inputs inside p regardless of depth & elements inbetween ?
It would affect any inputs below paragraphs regardless of depth.
p > input
would affect only first of those inputs ?
<p>
<input>
<input>
<input>
</p>
It would affect all direct children, as alykins suggested.