WP HOOKS
filtrod 4.4.0

rest_avatar_sizes

Args 1Plik wp-includes/rest-api.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the REST avatar sizes.

Use this filter to adjust the array of sizes returned by the rest_get_avatar_sizes function.

Parametry

ParametrTypOpis
$sizesint[]An array of int values that are the pixel sizes for avatars. Default <code>[ 24, 48, 96 ]</code>.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej
add_filter( 'rest_avatar_sizes', 'twoja_funkcja' );

function twoja_funkcja($param_1) {
	// Twój kod
}

Popularne w tej kategorii