html > body,html > body div,html > body p,html > body th,html > body td,html > body li,html > body dd,html > body textarea,html > body input {
font-size:10pt;
}


Deze code kwam ik tegen op een site, toen ik in de CSS-code snuffelde.
Kan iemand mij vertelde wat dit stukje doet?
het ziet er namelijk erg exotisch uit, vind ik namelijk...
Ik neem aan dat die 317 en 318 regelnummers zijn die je perongelijk hebt meegekopieerd?
Ja, dat klopt. Typfout...
Pas het even aan met de edit knop ;-)


To send different CSS rules to IE, we can use the child selector command which IE can't understand. The child selector command involves two elements, one of which is the child of the other. So, html>body refers to the child, body, contained within the parent, html.

Using the example of the header margin, our CSS command would be:

#header {margin-bottom: 3em;}
html>body #header {margin-bottom: 1em;}

IE can't understand the second CSS rule due to the html>body CSS command so will ignore it and use the first rule. All other browsers will use the second rule.
Bron Webcredible

Reageren