Enhanced Media Library icon
Media, Galleries & Sliders

Enhanced Media Library hooks reference

  • By webbistro
  • v2.9.4
  • Updated

Enhanced Media Library 2.9.4 has 13 actions and 5 filters, read directly from its source code on Nov 17, 2026. The list updates automatically when a new version is released.

How to use these hooks

Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.

functions.phpyour child theme
// Run your own code when Enhanced Media Library fires an action
add_action( 'edit_term_taxonomy', function( $term, $name ) {
	// Your code runs here.
}, 10, 2 );

// Change a value Enhanced Media Library is about to use
add_filter( 'attachment_fields_to_save', function( $post, $attachment_data ) {
	// Change $post here.
	return $post;
}, 10, 2 );

Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.

All hooks

  • core/taxonomies.php line 962
    /**
     * This filter is documented in wp-admin/includes/media.php
     */
    apply_filters( 'attachment_fields_to_save', $post, $attachment_data );
  • list_cats

    filter
    core/taxonomies.php line 748
    /**
     * This filter is documented in wp-includes/category-template.php
     */
    apply_filters( 'list_cats', $category->name, $category );
  • the_category

    filter
    core/taxonomies.php line 858 · used in 3 places
    apply_filters( 'the_category', $category->name );
  • core/taxonomies.php line 1233 · used in 2 places
    do_action( 'edit_term_taxonomy', $term, $taxonomy->name );
  • core/taxonomies.php line 1235 · used in 2 places
    do_action( 'edited_term_taxonomy', $term, $taxonomy->name );
  • core/options-pages.php line 878 · used in 2 places
    do_action( 'wpuxss_eml_extend_settings_page' );
  • core/options-pages.php line 1574 · used in 2 places
    apply_filters( 'wpuxss_eml_pro_add_options', $options );
  • core/options-pages.php line 264
    do_action( 'admin_enqueue_scripts', $hook_suffix );
  • core/options-pages.php line 267
    do_action( "admin_head-{$hook_suffix}" );
  • core/options-pages.php line 266
    do_action( "admin_print_scripts-{$hook_suffix}" );
  • core/options-pages.php line 265
    do_action( "admin_print_styles-{$hook_suffix}" );
  • core/options-pages.php line 1497
    do_action( 'delete_term_relationships', $attachment_id, $tt_ids );
  • core/options-pages.php line 1514
    do_action( 'deleted_term_relationships', $attachment_id, $tt_ids );
  • core/options-pages.php line 263
    do_action( "load-{$hook_suffix}" );
  • core/options-pages.php line 1622
    apply_filters( 'wpuxss_eml_pro_add_transients', $transients );
  • core/options-pages.php line 1373
    do_action( 'wpuxss_eml_pro_set_settings', $wpuxss_eml_backup );
  • enhanced-media-library.php line 893
    do_action( 'wpuxss_eml_set_options' );
  • enhanced-media-library.php line 132
    do_action( 'wpuxss_eml_set_site_options' );

Generated from Enhanced Media Library's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.

Can't find the right hook?

We can build the customisation for you. Describe what you need: