Make WordPress Core


Ignore:
Timestamp:
09/14/2023 01:11:29 AM (9 months ago)
Author:
joedolson
Message:

Administration: Use wp_admin_notice() in /wp-admin/includes.

Add usages of wp_admin_notice() and wp_get_admin_notice() on .notice-[type] in the root level of /wp-admin/includes. Ongoing task to implement new function across core.

Props costdev, joedolson.
See #57791.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-terms-list-table.php

    r56549 r56571  
    712712                <input type="hidden" name="post_type" value="<?php echo esc_attr( $this->screen->post_type ); ?>" />
    713713
    714                 <div class="notice notice-error notice-alt inline hidden">
    715                     <p class="error"></p>
    716                 </div>
     714                <?php
     715                wp_admin_notice(
     716                    '<p class="error"></p>',
     717                    array(
     718                        'type'               => 'error',
     719                        'additional_classes' => array( 'notice-alt', 'inline', 'hidden' ),
     720                        'paragraph_wrap'     => false,
     721                    )
     722                );
     723                ?>
    717724            </div>
    718725            </div>
Note: See TracChangeset for help on using the changeset viewer.