I have the following click event that is being fired multiple times although I click only once
$(document).on('click', '#addToList', function (event) {
event.preventDefault();
...
});
I read here you should use the off
method e.g.
$(element).off().on('click', function() {
// function body
});
however my jquery event is on the document since I load the control dynamically.
How do I add the off
code to my event?