Example 1 — Parent of Item “A”
Official idea: from li.item-a, mark the wrapping ul.
$("li.item-a").parent().append(" [parent]"); How It Works
- Start. Select
li.item-a. - Up one. Immediate parent is the inner
ul. - Stop. No further ancestors are visited.

