Make WordPress Core

Changes between Version 2 and Version 3 of Ticket #26872, comment 5


Ignore:
Timestamp:
01/19/2014 05:41:40 AM (11 years ago)
Author:
azaozz
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #26872, comment 5

    v2 v3  
    11Yeah, think the buttons IDs change depending on the button position and the instance. They are auto-generated from an incrementing value. Same for the toolbars and other containers.
    22
    3 There are better ways to determine when the editor is "ready". For example can use `tinymce.on( 'AddEditor', function( editor ) { editor.on( 'init', function() { [your code] } ): }):`. Also thinking to fire a custom jQuery event when an editor instance is initialized, perhaps something like `jQuery( document ).trigger( 'wp-tinymce-init', [ editor instance ] );`.
     3There are better ways to determine when the editor is "ready". For example can use `tinymce.on( 'AddEditor', function( editor ) { editor.on( 'init', function() { [your code] } ); });`. Also thinking to fire a custom jQuery event when an editor instance is initialized, perhaps something like `jQuery( document ).trigger( 'wp-tinymce-init', [ editor instance ] );`.
    44
    55Ref: http://www.tinymce.com/wiki.php/api4:class.tinymce, http://www.tinymce.com/wiki.php/api4:class.tinymce.Editor.