Answers for "jquery onclick fucntion"

44

jquery click function

$( "#target" ).click(function() {
  alert( "Handler for .click() called." );
});
Posted by: Guest on February-24-2020
3

jquery on click get element

$(document).on("click",".appDetails", function () {
   var clickedBtnID = $(this).attr('id'); // or var clickedBtnID = this.id
   alert('you clicked on button #' + clickedBtnID);
});
Posted by: Guest on September-07-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language