Adds a 'wp-post-image' class to post thumbnails. Internal use only.
Description
Uses the 'begin_fetch_post_thumbnail_html' and 'end_fetch_post_thumbnail_html' action hooks to dynamically add/remove itself so as to only filter post thumbnails.
Parameters
$attrstring[]
Array of thumbnail attributes including src, class, alt, title, keyed by attribute name.
Return
string[]
Modified array of attributes including the new 'wp-post-image' class.
Signature, return type and hooks compared across 5 parsed releases.
About this page
Parsed data
Generated from the wordpress-develop 7.1.0 tag, from src/wp-includes/media.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.