wpseek.com
WordPress开发者和主题制作者的搜索引擎



wp_sitemaps_get_max_urls › WordPress Function

Since5.5.0
已弃用n/a
wp_sitemaps_get_max_urls ( $object_type )
参数:
  • (string) $object_type Object type for sitemap to be filtered (e.g. 'post', 'term', 'user').
    Required: Yes
返回:
  • (int) The maximum number of URLs.
定义在:
文档:

Gets the maximum number of URLs for a sitemap.



源码

function wp_sitemaps_get_max_urls( $object_type ) {
	/**
	 * Filters the maximum number of URLs displayed on a sitemap.
	 *
	 * @since 5.5.0
	 *
	 * @param int    $max_urls    The maximum number of URLs included in a sitemap. Default 2000.
	 * @param string $object_type Object type for sitemap to be filtered (e.g. 'post', 'term', 'user').
	 */
	return apply_filters( 'wp_sitemaps_max_urls', 2000, $object_type );
}