Make WordPress Core


Ignore:
Timestamp:
11/20/2012 02:35:30 AM (12 years ago)
Author:
koopersmith
Message:

Media: Improve media buttons on the front end.

  • Use a less specific selector (the body, actually) to delegate opening the media dialog.
  • Allow the editor ID to be the empty string so the media_buttons action can be called without arguments.

see #22284, #21390.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/media.php

    r22679 r22699  
    391391
    392392    $img = '<span class="wp-media-buttons-icon"></span> ';
     393
     394    error_log( 'MEDIA_BUTTONS ' . print_r( func_get_args(), true ) );
    393395
    394396    echo '<a href="#" class="button insert-media add_media" data-editor="' . esc_attr( $editor_id ) . '" title="' . esc_attr__( 'Add Media' ) . '">' . $img . __( 'Add Media' ) . '</a>';
Note: See TracChangeset for help on using the changeset viewer.