[wp-trac] [WordPress Trac] #26881: Multiple wp_editor() on one page and link button broken

WordPress Trac noreply at wordpress.org
Sat Mar 28 19:03:31 UTC 2015

#26881: Multiple wp_editor() on one page and link button broken
 Reporter:  machinedean        |       Owner:
     Type:  defect (bug)       |      Status:  reopened
 Priority:  normal             |   Milestone:
Component:  Editor             |     Version:
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:
Changes (by torresio):

 * status:  closed => reopened
 * version:  3.8 =>
 * resolution:  worksforme =>


 Hello all,

 I've come across this bug in a feature recently created on a 4.1.1. While
 creating various wp_editors inside of different accordion tabs inside of a
 custom metabox, everything works except when trying to add a link / close
 the link modal. Selecting text, and clicking on the link button brings up
 the add link modal but trying to close the modal throws a JS error and
 cannot be closed, forcing a refresh. Here is the error:

 * Uncaught TypeError: Cannot read property 'focus' of undefined
   * wpLink.close

 Entering "window.wpActiveEditor" in the console shows the right textarea
 ID but "wpLink.textarea" returns undefined.

Ticket URL: <https://core.trac.wordpress.org/ticket/26881#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list