I have a clickable <td>
which does some action. However, strange things happen when I quickly make double click. Thus, I want to prevent it and make sure it is only single clickable event.
$.each(response, function(index) {
$('#myID').append('<tr><td onclick="select(this)" >'+ response[index] +'</td></tr>');
});
function select(element){
...
}
I tried to use jQuery's .one()
function, but this code above is a product of another event. So, I cannot use $(document).ready();
here. In my knowledge I have to make it like onclick="select(this)"
... And it works. But here I need to disable double clicking.
Any help?