apply_filters( 'wp_get_attachment_link', string $link_html, int $id, string|array $size, bool $permalink, bool $icon, string|bool $text )

Filters a retrieved attachment page link.


Parameters

$link_html

The page link HTML output.

$id

Post ID.

$size

Size of the image. Image size or array of width and height values (in that order). Default 'thumbnail'.

$permalink

Whether to add permalink to image. Default false.

$icon

Whether to include an icon. Default false.

$text

If string, will be link text. Default false.


Source

File: wp-includes/post-template.php

View on GitHub



Changelog

Changelog
Version Description
WP-2.7.0 Introduced.