i have (2) textareas. one is a regular textarea the other is and the reference for an (F)CKEditor. when a user types in the (F)CKEditor i want each keypress to be triggered and shown in the regular textarea. how do i do this?
this is my non-working code:
CKEDITOR.instances.ckeditor1.on('key', function (e)
{
var je = $.Event("keyup");
je.which = e.data.keyCode;
textArea.bind(je, private.bindKeyup);
textArea.trigger(je);
});
I can see a couple of reasons why your example isn’t working.
You’ll also probably want to remove the textarea.bind() call from the event handler. Putting it in there means that you will bind another copy of the event handler to the textarea every time a key is pressed in the ckeditor. probably not what you want.
Anyway, here is my sample