+ 1

If <body> is a parent element

Is a heading element a parent element too? If I changed the attribute of h1 to color="white" foes that mean paragraphs under it become white too?

28th Jul 2016, 3:40 PM
***
1 Odpowiedź
+ 3
A parent has children between its opening and closing tags. <body> is parent because other elements (children) are <body>inside</body>. Children of <body> could also be parents. Example: <ul> <li>... </li> <li>... </li> </ul> <ul> is a parent of a bunch of <li>'s.
28th Jul 2016, 8:56 PM
ZinC
ZinC - avatar