user2598808 user2598808 - 7 months ago 45
jQuery Question

TinyMCE - Multiple Rich Text Editors - How to get the focus of mous cursor to track which editor is selected

I have multiple TINYMCE Rich Text Editors in one page.

How can I track the focus to see which one is selected.

Cursor doesn't work on RTE always.

Refer the code here :

Please suggest.


I got the solution for this, posting the answer so that it will be useful for others.

We can get focus using the below code:

 var triggerElement =;

 var myEditor = tinyMCE.editors[triggerElement];