filtrod 3.7.0
wp_count_attachments
Opis — z kodu źródłowego
Filters the attachment counts by mime type.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$counts | \stdClass | An object containing the attachment counts by mime type. |
$mime_type | string | string[] | Array or comma-separated list of MIME patterns. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'wp_count_attachments', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'wp_count_attachments', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}Popularne w tej kategorii