filtrod 2.6.0
get_image_tag_class
Opis — z kodu źródłowego
Filters the value of the attachment's image tag class attribute.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$class | string | CSS class name or space-separated list of classes. |
$id | int | Attachment ID. |
$align | string | Part of the class name for aligning the image. |
$size | string | int[] | Requested image size. Can be any registered image size name, or an array of width and height values in pixels (in that order). |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_image_tag_class', 'twoja_funkcja', 10, 4 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_image_tag_class', 'twoja_funkcja', 10, 4 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4) {
// Twój kod
}Popularne w tej kategorii