how to write html code with click event in jquery function code example
Example 1: on click jquery
$( "#dataTable tbody tr" ).on( "click", function() {
console.log( $( this ).text() );
});
Example 2: onclick event in jquery ajac
$('a').click(function(){
$.ajax({
type: "POST",
url: "mysimplepage.php",
async: true,
data: { logDownload: true, file: $(this).attr("name") }
});
return false;
});