Filter hook 'wp_sitemaps_posts_pre_max_num_pages'

in WP Core File wp-includes/sitemaps/providers/class-wp-sitemaps-posts.php at line 200

Description

Filters the max number of pages before it is generated. Passing a non-null value will short-circuit the generation, returning that value instead.

Occurrences

Filename Line Number
wp-includes/sitemaps/providers/class-wp-sitemaps-posts.php 200

Parameters

Type Name Description
int|null $max_num_pages The maximum number of pages. Default null.
string $post_type Post type name.

PHP Doc

/**
		 * Filters the max number of pages before it is generated.
		 *
		 * Passing a non-null value will short-circuit the generation,
		 * returning that value instead.
		 *
		 * @since 5.5.0
		 *
		 * @param int|null $max_num_pages The maximum number of pages. Default null.
		 * @param string   $post_type     Post type name.
		 */