clanbite_players_get_display_avatar( int $player_id = 0, bool $suppress_filters = false, string|array $size = '', string $context = '', string $avatar_preset = '' ): stringReturns the players display avatar URL.
All Clanbite player avatar surfaces should resolve the image URL through this function so third-party code can override output once (XP overlays, rank badges as image, CDN URLs, etc.). Use the optional $context argument to vary behaviour by surface; it is passed to filters and avatar markup helpers.
Pass $avatar_preset as large, medium, or small to use the image sizes configured under Clanbite → Players (profiles, forums/social feeds, comments/replies). When set, it overrides $size.
Parameters
$player_id(int) OptionalThe Player/User unique identifier.
Default:
0$suppress_filters(bool) OptionalDisallows filtering of the value.
Default:
false$size(string|array) OptionalRegistered size name or array of width and height (ignored when preset is set).
Default:
''$context(string) OptionalLogical surface key (e.g.
player_avatar_block,user_nav,notifications).Default:
''$avatar_preset(string) OptionalOptional.
large,medium, orsmallfor settings-driven sizes.Default:
''
Returns
string
Defined in inc/extensions/players/functions.php