• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Child Selectors

A child selector is applied whenever an element is considered to be the "child" of some "parent" element. It uses a "greater-than" symbol (">") between at least two Web elements.

List elements can be considered the "children" of the "parent" ordered or unordered list tags. In a similar way, all displayed content on a Web page can be considered to be the child of the body tag. The child selector enables the Web author to specify that when a given child element appears after a certain parent element, it should be formatted in a way described. The following code sample provides two examples of this:


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint