Make WordPress Core

Changeset 54144


Ignore:
Timestamp:
09/13/2022 06:03:30 PM (4 years ago)
Author:
davidbaumwald
Message:

General: Add a new filter for the_posts_pagination_args.

Props pbiron, joyously, audrasjb, robinwpdeveloper.
Fixes 53392.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/link-template.php

    r53910 r54144  
    28712871                );
    28722872
     2873                /**
     2874                 * Filters the arguments for posts pagination links.
     2875                 *
     2876                 * @since 6.1.0
     2877                 *
     2878                 * @param array $args {
     2879                 *     Optional. Default pagination arguments, see paginate_links().
     2880                 *
     2881                 *     @type string $screen_reader_text Screen reader text for navigation element.
     2882                 *                                      Default 'Posts navigation'.
     2883                 *     @type string $aria_label         ARIA label text for the nav element. Default 'Posts'.
     2884                 *     @type string $class              Custom class for the nav element. Default 'pagination'.
     2885                 * }
     2886                 */
     2887                $args = apply_filters( 'the_posts_pagination_args', $args );
     2888
    28732889                // Make sure we get a string back. Plain is the next best thing.
    28742890                if ( isset( $args['type'] ) && 'array' === $args['type'] ) {
Note: See TracChangeset for help on using the changeset viewer.