File: wp-includes/media.php
-
Determines the output format for the image editor.
-
Filters the attachment ID to allow short-circuit the function.
-
functionwp_img_tag_add_auto_sizes()
Adds ‘auto’ to the sizes attribute to the image, if the image is lazy loaded and does not already include it.
-
Filters whether auto-sizes for lazy loaded images is enabled.
-
Checks whether the given ‘sizes’ attribute includes the ‘auto’ keyword as the first item in the list.
-
Enqueues a CSS rule to fix potential visual issues with images using `sizes=auto`.
-
functionwp_get_avif_info()
Extracts meta information about an AVIF file: width, height, bit depth, and number of channels.
-
Filters whether to short-circuit loading optimization attributes.
-
Filters the header-specific contexts.
-
Filters the loading optimization attributes.
-
functionwp_high_priority_element_flag()
Accesses a flag that indicates if an element is a possible candidate for `fetchpriority=’high’`.
-
Filters the minimum square-pixels threshold for an image to be eligible as the high-priority image.
-
Gets loading optimization attributes.
-
Determines whether to add `fetchpriority=’high’` to loading attributes.
-
Adds optimization attributes to an `img` HTML tag.
-
Filters the context in which wp_get_attachment_image() is used.
-
Filters the `decoding` attribute value to add to an image. Default `async`.
-
Filters an img tag within the content for a given context.
-
functionwp_omit_loading_attr_threshold()
Gets the threshold for how many of the first content media elements to not lazy-load.
-
Filters the threshold for how many of the first content media elements to not lazy-load.
-
Increases an internal content media count variable.
-
Filters the image editor output format mapping.
-
functionwp_get_webp_info()
Extracts meta information about a WebP file: width, height, and type.
-
Filters whether the Media Library grid has infinite scrolling. Default `false`.
-
functionget_adjacent_image_link()
Gets the next or previous image link that has the same post parent.
-
functionget_next_image_link()
Gets the next image link that has the same post parent.
-
functionget_previous_image_link()
Gets the previous image link that has the same post parent.
-
functionwp_getimagesize()
Allows PHP’s getimagesize() to be debuggable when necessary.
-
functionwp_iframe_tag_add_loading_attr()
Adds `loading` attribute to an `iframe` HTML tag.
-
Filters the `loading` attribute value to add to an iframe. Default `lazy`.