WordPress.org

Make WordPress Core

Changeset 24419


Ignore:
Timestamp:
06/06/2013 04:49:25 PM (8 years ago)
Author:
markjaquith
Message:

Properly uncheck the "new tab" box when editing a non-new-tab link.

Previously, if you had just edited a new-tab link, a subsequent edit of a non-new-tab link would mistakenly keep the checkbox checked.

props sc0ttkclark. fixes #24520.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/js/wplink.js

    r23515 r24419  
    114114                inputs.title.val( ed.dom.getAttrib(e, 'title') );
    115115                // Set open in new tab.
    116                 if ( "_blank" == ed.dom.getAttrib(e, 'target') )
    117                     inputs.openInNewTab.prop('checked', true);
     116                inputs.openInNewTab.prop('checked', ( "_blank" == ed.dom.getAttrib( e, 'target' ) ) );
    118117                // Update save prompt.
    119118                inputs.submit.val( wpLinkL10n.update );
Note: See TracChangeset for help on using the changeset viewer.