acf/schema/auto_add_image

acf/schema/auto_add_image

Hook Type: filter

See hook in core

Displaying hooks found in version: advanced-custom-fields.6.8.0

apply_filters('acf/schema/auto_add_image') is found 1 times:

  • /src/AI/GEO/Outputs/Posts.php line 204
    		 * @param bool    $add_image  Whether to add the featured image. Default true.
    		 * @param WP_Post $post       The post object.
    		 * @param string  $post_type  The post type.
    		 */
    		$add_image = apply_filters( 'acf/schema/auto_add_image', true, $post, $post_type );
    
    		// Add featured image if available and enabled.
    		if ( $add_image && has_post_thumbnail( $post ) ) {
    			$thumbnail_id  = get_post_thumbnail_id( $post );
    			$thumbnail_url = wp_get_attachment_image_url( $thumbnail_id, 'full' );