MLAModal

Class MLA (Media Library Assistant) Modal contains enhancements for the WordPress 3.5+ Media Manager

package

Media Library Assistant

since 1.20

Methods

Display a monthly dropdown for filtering items

_months_dropdown( $post_type) : array
static

Adapted from /wp-admin/includes/class-wp-list-table.php function months_dropdown()

since 1.20

Arguments

$post_type

Response

array

( value => label ) pairs

Initialization function, similar to __construct()

initialize() : void
static
since 1.20

Add the hidden form for the "Search Terms" popup modal window, but only once per page load

mla_add_terms_search_form() : void
static
since 1.90

Add the styles and scripts for the "Search Terms" popup modal window, but only once per page load

mla_add_terms_search_scripts() : void
static
since 1.90

Clean up the 'save-attachment-compat' values, removing taxonomy updates MLA already handled

mla_admin_init_action() : void
static
since 1.20

Echo the hidden form for the "Search Terms" popup modal window

mla_echo_terms_search_form() : void
static
since 1.90

Adds settings values to be passed to the Media Manager in /wp-includes/js/media-views.js.

mla_media_view_settings_filter( $settings,  $post) : array
static

Declared public because it is a filter.

since 1.20

Arguments

$settings

$post

Response

array

updated $settings array

Adds string values to be passed to the Media Manager in /wp-includes/js/media-views.js.

mla_media_view_strings_filter( $strings,  $post) : array
static

Declared public because it is a filter.

since 1.20

Arguments

$strings

$post

Response

array

updated $strings array

Prints the templates used in the MLA Media Manager enhancements.

mla_print_media_templates_action() : void
static

Declared public because it is an action.

since 1.20

Extract value and text elements from Dropdown HTML option tags

mla_terms_options( $markup) : array
static
since 1.20

Arguments

$markup

Response

array

( 'class' => $class_array, 'value' => $value_array, 'text' => $text_array )

Build the hidden form for the "Search Terms" popup modal window

mla_terms_search_form() : string
static
since 1.90

Response

string

HTML

markup for hidden form

Enqueues the mla-media-modal-scripts.js file, adding it to the Media Manager scripts.

mla_wp_enqueue_media_action() : void
static

Declared public because it is an action.

since 1.20

Constants

Slug for localizing and enqueueing CSS - Add Media and related dialogs

JAVASCRIPT_MEDIA_MODAL_STYLES
since
var

Slug for localizing and enqueueing JavaScript - Add Media and related dialogs

JAVASCRIPT_MEDIA_MODAL_SLUG
since
var

Object name for localizing JavaScript - Add Media and related dialogs

JAVASCRIPT_MEDIA_MODAL_OBJECT
since
var

Object name for localizing JavaScript - Terms Search popup

JAVASCRIPT_TERMS_SEARCH_OBJECT
since
var

Properties

Share the settings values between mla_media_view_settings_filter and mla_print_media_templates_action

mla_media_modal_settings : array
static
since
var

Type(s)

array