WordPress at a glance
function is not described

get_usernumposts() WP 0.71

Deprecated in 3.0.0. It is no longer supported and can be removed in future releases. Use count_user_posts() instead.

Retrieves the number of posts a user has written.

  • See: count_user_posts()

No Hooks.


Int. Number of posts the given user has written.


get_usernumposts( $userid );
$userid(int) (required)
User to count posts for.

Code of get usernumposts: wp-includes/deprecated.php WP 5.2.2

function get_usernumposts( $userid ) {
	_deprecated_function( __FUNCTION__, '3.0.0', 'count_user_posts()' );
	return count_user_posts( $userid );