wpseek.com
A WordPress-centric search engine for devs and theme authors



wp_get_attachment_image › WordPress Filter Hooks

Since5.6.0
Deprecatedn/a
apply_filters( 'wp_get_attachment_image', $html, $attachment_id, $size, $icon, $attr )
Parameters: (5)
  • () html HTML img element or empty string on failure.
    Required: Yes
  • () attachment_id Image attachment ID.
    Required: Yes
  • () size Requested image size. Can be any registered image size name, or an array of width and height values in pixels (in that order).
    Required: Yes
  • () icon Whether the image should be treated as an icon.
    Required: Yes
  • () attr Array of attribute values for the image markup, keyed by attribute name. See wp_get_attachment_image().
    Required: Yes
Defined at:
Codex:

Filters the HTML img element representing an image attachment.





Source

return apply_filters( 'wp_get_attachment_image', $html, $attachment_id, $size, $icon, $attr );