jquery .click issue
jquery .click issue
Hi,
I am new to jquery.
I got a requirement to enable and disable a click event of the href, based on few condition.
Placed the jquery code as
To disable the Href & Click:
$(reqObjNameRun).removeAttr('href');
$(reqObjNameRun).removeAttr('onclick');
To enable the Href & Click:
$(reqObjName).attr("href", '#');
$(reqObjName).click(function() {
executeStandAlone(stepName, accountNumber);
});
It works good at the first run. (First Disable , then Enabled it)
When I try to disable again, I am not able to disable it.
Any quick help is highly appreciated.