Filter hook 'pre_wp_get_loading_optimization_attributes'
in WP Core File wp-includes/media.php at line 5738
Description
Filters whether to short-circuit loading optimization attributes. Returning an array from the filter will effectively short-circuit the loading of optimization attributes, returning that value instead.
Occurrences
Filename |
Line Number |
wp-includes/media.php |
5738 |
Parameters
Type |
Name |
Description |
array|false |
$loading_attrs |
False by default, or array of loading optimization attributes to short-circuit. |
string |
$tag_name |
The tag name. |
array |
$attr |
Array of the attributes for the tag. |
string |
$context |
Context for the element for which the loading optimization attribute is requested. |
PHP Doc
/**
* Filters whether to short-circuit loading optimization attributes.
*
* Returning an array from the filter will effectively short-circuit the loading of optimization attributes,
* returning that value instead.
*
* @since 6.4.0
*
* @param array|false $loading_attrs False by default, or array of loading optimization attributes to short-circuit.
* @param string $tag_name The tag name.
* @param array $attr Array of the attributes for the tag.
* @param string $context Context for the element for which the loading optimization attribute is requested.
*/