WordPress.org

Make WordPress Core


Ignore:
Timestamp:
11/15/2021 10:23:01 PM (2 months ago)
Author:
joedolson
Message:

Taxonomy: Display update notices when adding terms.

Display notice and announce to screen readers when a new term is added.

Props manishamakhija, birgire, dilipbheda, afercia, hellofromTonya.
Fixes #42937.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/ajax-actions.php

    r52169 r52170  
    11031103    $parents = ob_get_clean();
    11041104
     1105    require ABSPATH . 'wp-admin/includes/edit-tag-messages.php';
     1106
     1107    $message = '';
     1108    if ( isset( $messages[ $tax->name ][1] ) ) {
     1109        $message = $messages[ $tax->name ][1];
     1110    } elseif ( isset( $messages['_item'][1] ) ) {
     1111        $message = $messages['_item'][1];
     1112    }
     1113
    11051114    $x->add(
    11061115        array(
    11071116            'what'         => 'taxonomy',
     1117            'data'         => $message,
    11081118            'supplemental' => compact( 'parents', 'noparents' ),
    11091119        )
Note: See TracChangeset for help on using the changeset viewer.