javascript - Jquery on click event is not working on dynamically added Custom tags -


this question has answer here:

jquery on click event not working on dynamically added custom tags

my code

  $("[addtoship='yes']").on('click', function() {          alert('ship added')   }); 

href <a href="#" addtoship='yes' myval="10235">add more ship</a>

i trying using .on still it's not working

$(document/commonparentselector).on('click', "[addtoship='yes']", function () {     alert('ship added') }); 

Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -