Working With Combinators



This uses a Child Selector

This group of text is in a paragraph tag which is initially set to be the color red, however it appears blue because it is a paragraph tag within a "section1 class.



This uses an Adjacent Sibling Selector

This group of text is in a paragraph tag which is initially set to be the color red, however because it is also set as an adjacent sibling of the class "section1" within a paragraph tag it appears green, as it appears right after the "section2" class.



This uses a General Sibling Selector

This group of text is in a paragraph tag which is initially set to be the color red, however because it is also set as a general sibling selector, and comes after a the class of "section3" (Even with something else inbetween) the entire text appears dark blue.



Mouse Over and I will Change Color! (even though I get a bit weird...)