get_post_gallery_images

SummerySummery

Checks a post’s content for galleries and return the image srcs for the first found gallery

Syntax

get_post_gallery_images( int|WP_Post $post )

ParametersParameters

$post

(int|WP_Post) (Optional) Post ID or WP_Post object. Default is global $post.

ReturnReturn

(string[]) A list of a gallery's image srcs in order.

SourceSource

File: wp-includes/media.php


			

ChangelogChangelog

Changelog
Version Description
3.6.0 Introduced.

See alsoSee also

Scroll to Top