Clanbite Players

apply_filters( 'clanbite_players_get_display_age', string $age, int $player_id, string $birthday )

Allows filtering of the players display age, this can be bypassed by setting $suppress_filters param to true.

Filter PHP

Parameters

$age (string)

Computed age.

$player_id (int)

Player (user) ID.

$birthday (string)

Birthday the age was computed from.

Example

add_filter( 'clanbite_players_get_display_age', function ( $age, $player_id, $birthday ) {
	// Change $age here.
	return $age;
}, 10, 3 );

Defined in inc/extensions/players/functions.php

Changelog

VersionDescription
1.3.0Updated.