[wp-trac] [WordPress Trac] #40083: if wp_editor is used in a metabox and you change 'visual' to 'text' and save, it affects the main editor too

WordPress Trac noreply at wordpress.org
Thu Mar 9 21:36:20 UTC 2017


#40083: if wp_editor is used in a metabox and you change 'visual' to 'text' and
save, it affects the main editor too
--------------------------+------------------------------
 Reporter:  shamai        |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  TinyMCE       |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  close         |     Focuses:  administration
--------------------------+------------------------------
Changes (by azaozz):

 * keywords:   => close
 * version:  4.7.3 =>


Comment:

 This is expected behavior. Most users prefer either the Visual or the Text
 editor. The user preference for which editor to load first is "global".

 In your plugin you can change the behavior by setting it to the state of
 one of the editors `onbeforeunload`. See:
 https://core.trac.wordpress.org/browser/tags/4.7.3/src/wp-
 admin/js/editor.js#L84 and
 https://core.trac.wordpress.org/browser/tags/4.7.3/src/wp-
 admin/js/editor.js#L115.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/40083#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list