tracking focus in CKEDITOR


/ Published in: JavaScript
Save to your folder(s)

tested with CKEDITOR 3.0 and Firefox 3.6.12 and IE 8


Copy this code and paste it in your HTML
  1. //check if any ckeditor instance has focus
  2. if(CKEDITOR.currentInstance)
  3. console.log('editor has focus!');
  4.  
  5. //adding on focus handler
  6. CKEDITOR.instances.ckeditor.on('focus', function(){
  7. console.log('focus')
  8. });

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.