filtrdynamicznyod 3.5.0
{$adjacent}_image_link
Args 4Plik wp-includes/media.php
Opis — z kodu źródłowego
Filters the adjacent image link.
The dynamic portion of the hook name, $adjacent, refers to the type of adjacency, either 'next', or 'previous'.
Possible hook names include:
next_image_linkprevious_image_link
Hook dynamiczny — możliwe nazwy
next_image_linkprevious_image_linkParametry
| Parametr | Typ | Opis |
|---|---|---|
$output | string | Adjacent image HTML markup. |
$attachment_id | int | Attachment ID |
$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). |
$text | string | Link text. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( '{$adjacent}_image_link', '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( '{$adjacent}_image_link', 'twoja_funkcja', 10, 4 );
function twoja_funkcja($param_1, $param_2, $param_3, $param_4) {
// Twój kod
}Popularne w tej kategorii