Why ul gets triggered when I click on li?
I have this html: <ul class='loc-list'> <li id="where_7" class="cont-list">North America <ul> <li id="contry_114" class="contry-list">canada</li> <li id="contry_115" class="contry-list">mexico</li> <li id="contry_117" class="contry-list">united states</li> </ul> </li> </ul> Now I have written two jquery functions onclick of list as: 1 st : $(".cont-list").on("click", function(event){ alert("clicked on continent's list"); // working fine }; 2 nd : $(".contry-list").on("click", function(event){ alert("clicked on country's list"); // not working! }; Here when I click on cont-list it get called