File: wp-includes/media.php
-
Adds `srcset` and `sizes` attributes to an existing `img` HTML tag. -
Filters whether to add the `srcset` and `sizes` HTML attributes to the img tag. Default `true`. -
function wp_lazy_loading_enabled() Determines whether to add the `loading` attribute to the specified tag in the specified context. -
Filters whether to add the `loading` attribute to the specified tag in the specified context. -
function wp_filter_content_tags() Filters specific tags in post content and modifies their markup. -
function wp_image_src_get_dimensions() Determines an image’s width and height dimensions based on the source file. -
function wp_image_file_matches_image_meta() Determines if the image meta data is for the image source file. -
Filters whether an image path or URI matches image meta. -
function _wp_add_additional_image_sizes() Adds additional default image sub-sizes. -
Filters whether to proceed with making an image sub-size with identical dimensions with the original/source image. Differences of 1px may be due to rounding and are ignored. -
function wp_get_registered_image_subsizes() Returns a normalized list of all currently registered image sub-sizes. -
Registers the personal data exporter for media. -
function wp_media_personal_data_exporter() Finds and exports attachments associated with an email address. -
Allows showing or hiding the “Create Video Playlist” button in the media library. -
Allows overriding the list of months displayed in the media library. -
Allows showing or hiding the “Create Audio Playlist” button in the media library. -
function wp_get_additional_image_sizes() Retrieves additional image sizes. -
function wp_image_matches_ratio() Helper function to test if aspect ratios for two images match. -
Pre-filters the image meta to be able to fix inconsistencies in the stored data. -
function _wp_get_attachment_relative_path() Gets the attachment path relative to the upload directory. -
function wp_image_add_srcset_and_sizes() Adds ‘srcset’ and ‘sizes’ attributes to an existing ‘img’ element. -
Filters the maximum image width to be included in a ‘srcset’ attribute. -
Filters an image’s ‘srcset’ sources. -
function wp_get_attachment_image_sizes() Retrieves the value for an image attachment’s ‘sizes’ attribute. -
function wp_calculate_image_sizes() Creates a ‘sizes’ attribute value for an image. -
Filters the output of ‘wp_calculate_image_sizes()’. -
function wp_get_attachment_image_srcset() Retrieves the value for an image attachment’s ‘srcset’ attribute. -
function wp_calculate_image_srcset() A helper function to calculate the image sources to include in a ‘srcset’ attribute. -
Filters the output of image_get_intermediate_size() -
function wp_get_attachment_image_url() Gets the URL of an image attachment.