Reputation: 21899
Is there a way to capture JavaScript events for when a contenteditable
element begins and ends editing?
Upvotes: 1
Views: 553
Reputation: 324507
As Nick said, focus
and blur
will work, and in all major browsers. IE also has a number of related events (although none of these are implemented in other browsers as far as I know): activate
, deactivate
, beforeactivate
, beforedeactivate
and beforeeditfocus
Upvotes: 0
Reputation: 630379
I'm not sure exactly here, but aren't you after focus
and blur
? I'm not sure what else "begins and ends editing" could be translated to that has a different timing than those, unless you mean an event for every keystroke, etc.
Upvotes: 4