| using the * universal selector *, body |
nyteshade

msg:4382065 | 1:43 pm on Nov 1, 2011 (gmt 0) | I recently discovered some CSS that will fill the viewport with the current document at boagworld. It's this:
*, body { margin: 0; padding: 0; }
#container { display: block; position: absolute; min-height: 100%; }
#content { display: block; margin-bottom: 3em; }
#footer { position: absolute; display: block; bottom: 0; height: 3em } I understand everything here execpt the " *, body "? I mean, if you use * then it selects all elements including body right? Then why include body, it's not a descendant as used here, right? Also, wouldn't html* accomplish the same thing? I've got a decent handle on CSS but the symbols leave me scratching my head sometimes. Thx all.
|
topr8

msg:4382072 | 2:00 pm on Nov 1, 2011 (gmt 0) | * means everything, the body in the first line of code is superfluous
|
nyteshade

msg:4382082 | 2:14 pm on Nov 1, 2011 (gmt 0) | I thought as much, but I needed to do a brain-check, thanks!
|
|
|