title: CKEditor and keypress event
body: <p>I have a simple page that has two input text fields and one textarea field. I have been working by associating a keypress event for these three form fields. But now I have changed the textarea into rich editor using CKEditor. I used the ckeditor.js, adapters/jquery.js, and other relevant files from CKEditor. But now the keypress event associated with the textarea fails. Here is part of the code that I'm working with.</p>
  
  <pre><code>.....
  &lt;input type="text" id="sub" name="subject" autocomplete="off"&gt;
  &lt;input type="text" id="rec" name="recvr" autocomplete="off"&gt;
  
   &lt;textarea  cols="90" rows="18"  name="body" id="content" &gt;  &lt;/textarea&gt;
  
  ...
  </code></pre>
  
  <p>And in my jquery, I have the following to create the CKEditor instance and associate a keypress event for the form fields:</p>
  
  <pre><code>....
   if(CKEDITOR.instances['body']){
      delete CKEDITOR.instances['body'];
   }
   CKEDITOR.replace('body');
  
  /*translate letters on key press */
  $("input#sub").keypress(function(event){
    //alert(this.form);
    TranslateOnKeyPress(event, this.form);
  });
  /*$("textarea#body").keypress(function(event){
       // alert(this.form);
       TranslateOnKeyPress(event, this.form);
  });
  */
   CKEDITOR.instances['body'].on('instanceReady', function() {
        this.document.on('keypress', function(event){
            alert(event + "&gt;&gt; " + this.form + " &lt;&lt;&lt; ");
            TranslateOnKeyPress(event, this.form);
        });
   });
  ....
  </code></pre>
  
  <p>So, the problem now is <code>this.form</code> in the CKEditor instance at the last returns <code>undefined</code> and the TranslateOnKeyPress(event, this.form) stops working. The other text fields work perfectly. So, my problem seems on properly handling the form event with the function. Can anyone give me his hand here? Your help will be highly appreciated.</p>
  
  <p>Thanks,</p>