ASP.NET - How to call onblur event to CKEditor control in asp.net?

Asked By sanket patil on 26-Sep-12 12:35 AM
hi, i m using CKEditor control in my asp.net project. After typing anything in editor, i want to call onblur event. please provide me proper solution.
Hemanth Kumar replied to sanket patil on 26-Sep-12 02:01 AM
Once Check this link

http://forums.asp.net/t/1695095.aspx/1

try this - manish postariya replied to Hemanth Kumar on 26-Sep-12 01:37 PM

<script type="text/javascript" src="ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="ckeditor/adapters/jquery.js"></script>...

// src: http://docs.cksource.com/ckeditor_api/symbols/CKEDITOR.config.html#.toolbarCanCollapse
var global_ckeditor_config = {
      toolbar:
      [
        ['Bold', 'Italic', 'Underline', /*'Strike', '-', */ 'NumberedList', 'BulletedList' /*, '-', 'Link', 'Unlink'*/],
        [ 'Cut', 'Copy', 'Paste', 'PasteFromWord', '-', 'SpellChecker', 'Table'],
        /*['Image','Table','HorizontalRule', 'SpecialChar'],*/
        ['JustifyLeft', 'JustifyCenter', 'JustifyRight']
        /*'/',
        ['Styles','Format','Font','FontSize'],
        ['TextColor','BGColor']*/
      ],
      skin : 'v2',
      width : '75%',
      toolbarCanCollapse : false,
      uiColor: '#eee',
      enterMode : 2 // 1 - new <p>; 2 - <br/>; 3 - new <div> see /ckeditor/_samples/enterkey.html
};

$(document).ready(function () {
    $('#YOUR_TEXTAREA_ID').ckeditor(global_ckeditor_config);
    
    CKEDITOR.instances.YOUR_TEXTAREA_ID.on('blur', function() {
      alert('onblur 123');
    });
});