Besides the invalid HTML cited by @ProgramFOX, it looks like you have misinterpreted the meaning of
nth-child()
.
As described in the jQuery documentation (
http://api.jquery.com/nth-child-selector/[
^]), the
:nth-child()
selector counts all children of each parent, regardless of any selector attached to the pseudo-class.
So
.toolTipList:nth-child(2)
refers to any element having class
toolTipList
that is also the second child of its parent. It does
not necessarily refer to the second
toolTipList
element.
If you meant for your HTML to be this:
<div class="k-tooltip-content">
<ul class="toolTipList"> ... </ul>
<hr>
<ul class="toolTipList">
<li><span>Bing Ads</span></li>
<li><a>Campaigns</a></li>
<li><a>Test</a></li>
</ul>
</div>
then there is no element that has the
toolTipList
class that is also a 2nd child (the
<hr>
element is the 2nd child of its parent, but the
toolTipList
elements are 1st and 3rd children).