On this page
apply_filters( "{$adjacent}_image_link", string $output, int $attachment_id, string|int[] $size, string $text )
Filters the adjacent image link.
Description
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
Parameters
$outputstring-
Adjacent image HTML markup.
$attachment_idint-
Attachment ID
$sizestring|int[]-
Requested image size. Can be any registered image size name, or an array of width and height values in pixels (in that order).
$textstring-
Link text.
Source
File: wp-includes/media.php. View all references
return apply_filters( "{$adjacent}_image_link", $output, $attachment_id, $size, $text );
Related
Used By
| Used By | Description |
|---|---|
| get_adjacent_image_link() wp-includes/media.php | Gets the next or previous image link that has the same post parent. |
Changelog
| Version | Description |
|---|---|
| 3.5.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/adjacent_image_link