[wp-trac] [WordPress Trac] #34559: get_post_galleries does not return the galleries properly
WordPress Trac
noreply at wordpress.org
Mon Nov 2 22:22:34 UTC 2015
#34559: get_post_galleries does not return the galleries properly
-------------------------------------------+-----------------------------
Reporter: darius00klokj | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 4.3.1
Severity: normal | Keywords:
Focuses: accessibility, administration |
-------------------------------------------+-----------------------------
The function get_post_galleries is missing:
{{{#!php
<?php
elseif ( ! empty( $shortcode[5] ) && has_shortcode( $shortcode[5],
'gallery' ) ) {
}}}
----
and iterate on the content returned by '''$shortcode[5]'''.
This occures when the galleries are within anther shortcode, example:
{{{
[block_div]
some text [gallery ids="1,2,3"]
[/block_div]
}}}
in the example the above the '''has_shortcode''' will return true, but the
'''get_post_galleries''' will be an empty array.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34559>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list