Clanbite Since 1.3.0
clanbite_avatar_badge_html( string $shape, array $badge, string $bind = '' ): stringThe rank badge: a small shape (hexagon for hexagon avatars) at the avatar's lower right, holding the level icon or number.
Server rendering takes the data from $badge; Interactivity rendering passes $bind (a path to an avatar_badge object) and the browser fills in the icon, number and label.
Parameters
$shape(string) Requiredcircle,squareorhexagon.$badge(array<string, mixed>) RequiredData from
clanbite_get_avatar_badge()(ignored when$bindis set).$bind(string) OptionalInteractivity path of the
avatar_badgeobject, or empty for server rendering.Default:
''
Returns
string Badge markup, or an empty string when there is nothing to show.
Defined in inc/avatar-helpers.php
Changelog
| Version | Description |
|---|---|
| 1.3.0 | Introduced. |