Maybe attempts to generate attachment metadata, if missing.
Parameters
$attachmentWP_Postrequired- Attachment object.
Source
$shortcode_attrs,
array(
'src' => array_values( array_unique( $srcs ) ),
)
);
}
}
}
}
if ( has_block( 'gallery', $post->post_content ) ) {
$post_blocks = parse_blocks( $post->post_content );
while ( $block = array_shift( $post_blocks ) ) {
$has_inner_blocks = ! empty( $block['innerBlocks'] );
// Skip blocks with no blockName and no innerHTML.
if ( ! $block['blockName'] ) {
continue;
}
Changelog
| Version | Description |
|---|---|
| 3.9.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.