difference be :first and :first-child not clear
- by sushil bharwani
i am having a ul li list
< ul >
< li > Parent
< ul >
< li >
child1
< /li >
< li >
child2
< /li >
< /ul >
< /li >
< /ul >
and i am trying to use a selector jQuery('ul li:first') and jQuery('ul li:first-child') both giving the same result this makes me confused about the difference between the two is there a example which clarifies the difference between two selectors