wpseo_image_attribute_containing_id

wpseo_image_attribute_containing_id

Hook Type: filter

See hook in core

Displaying hooks found in version: wordpress-seo.24.8.1

apply_filters('wpseo_image_attribute_containing_id') is found 2 times:

  • /src/images/Application/image-content-extractor.php line 89
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    * Defaults to "class", which is where WP natively stores the image IDs, in a `wp-image-<ID>` format.
     *
     * @api string The attribute to be used to extract image IDs from.
     */
    $attribute = \apply_filters( 'wpseo_image_attribute_containing_id', 'class' );
    while ( $processor->next_tag( $query ) ) {
        $src_raw = $processor->get_attribute( 'src' );
        if ( ! $src_raw ) {
            continue;
        }
  • /src/images/Application/image-content-extractor.php line 124
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    * Defaults to "class", which is where WP natively stores the image IDs, in a `wp-image-<ID>` format.
     *
     * @api string The attribute to be used to extract image IDs from.
     */
    $attribute = \apply_filters( 'wpseo_image_attribute_containing_id', 'class' );
     
    \libxml_use_internal_errors( true );
    $post_dom = new DOMDocument();
    $post_dom->loadHTML( '<?xml encoding="' . $charset . '">' . $content );
    \libxml_clear_errors();