wp_img_tag_add_loading_attr


wp_img_tag_add_loading_attr ( $image, $context )

Parameters:
  • (string) image The HTML `img` tag where the attribute should be added.
  • (string) context Additional context to pass to the filters.
Returns:
  • (string) Converted `img` tag with `loading` attribute added.
Defined at:

Description

Adds `loading` attribute to an `img` HTML tag.

Related Functions

wp_img_tag_add_srcset_and_sizes_attr, wp_ajax_add_link_category, wp_script_add_data, wp_image_editor, wp_lazy_loading_enabled

Top Google Results

User discussions

wpseek mobile