mla_attachment_array_fetch_references_handler()
mla_fetch_attachment_references_handler()
mla_flush_mla_galleries_handler()
_build_mla_galleries()
_search_mla_galleries()
$galleries
$mla_galleries
Class MLA (Media Library Assistant) Query provides database query support for "where-used" reporting needs
package | Media Library Assistant |
---|---|
since | 2.20 |
mla_flush_mla_galleries_handler(string $option_name) : void
Called from MLAQuery::mla_flush_mla_galleries, which handles conditional loading of this file.
since | 1.00 |
---|
string
name of the gallery's cache/option variable
_build_mla_galleries(string $option_name, array $galleries_array, string $shortcode, boolean $exclude_revisions) : boolean
since | 0.70 |
---|
string
name of the gallery's cache/option variable
array
by reference to the private static galleries array variable
string
the shortcode to be searched for and processed
boolean
true to exclude revisions from the search
boolean
true if the galleries array is not empty_search_mla_galleries(array $galleries_array, int $attachment_id) : array
since | 0.70 |
---|
array
by reference to the private static galleries array variable
int
the attachment ID to be searched for and processed
array
All posts/pages with one or more galleries that include the attachment. The array key is the parent_post ID; each entry contains post_title and post_type.$galleries : array
This array contains all of the objects containing one or more [gallery] shortcodes and array(s) of which attachments each [gallery] contains. The arrays are built once each page load and cached for subsequent calls.
The outer array is keyed by post_id. It contains an associative array with: ['parent_title'] post_title of the gallery parent, ['parent_type'] 'post' or 'page' or the custom post_type of the gallery parent, ['parent_status'] 'publish', 'private', 'future', 'pending', 'draft' ['results'] array ( ID => ID ) of attachments appearing in ANY of the parent's galleries. ['galleries'] array of [gallery] entries numbered from one (1), containing: galleries[X]['query'] contains a string with the arguments of the [gallery], galleries[X]['results'] contains an array ( ID ) of post_ids for the objects in the gallery.
since | 0.70 |
---|
$mla_galleries : array
This array contains all of the objects containing one or more [mla_gallery] shortcodes and array(s) of which attachments each [mla_gallery] contains. The arrays are built once each page load and cached for subsequent calls.
since | 0.70 |
---|