Ticket #28825: 28825.patch
File 28825.patch, 1.6 KB (added by , 11 years ago) |
---|
-
src/wp-admin/upload.php
33 33 add_screen_option( 'mime', array( 'label' => __( 'Mime-type' ) ) ); 34 34 35 35 require_once( ABSPATH . 'wp-admin/admin-header.php' ); 36 ?> 37 <div class="wrap"> 38 <h2> 39 <?php 40 echo esc_html( $title ); 41 if ( current_user_can( 'upload_files' ) ) { ?> 42 <a href="media-new.php" class="add-new-h2"><?php echo esc_html_x('Add New', 'file'); ?></a><?php 43 } 44 ?> 45 </h2> 46 </div> 47 <?php 36 48 include( ABSPATH . 'wp-admin/admin-footer.php' ); 37 49 exit; 38 50 } -
src/wp-includes/js/media-grid.js
201 201 libraryState = new media.controller.Library({ 202 202 library: media.query( options.library ), 203 203 multiple: options.multiple, 204 title: options.title,204 title: '', 205 205 priority: 20, 206 206 toolbar: false, 207 207 router: false, … … 209 209 filterable: 'mime-types' 210 210 }); 211 211 212 libraryState._renderTitle = function( view ) {213 var text = this.get('title') || '';214 view.$el.addClass( 'wrap' );215 text += '<a class="add-new-h2">Add New</a>';216 view.$el.html( text );217 };218 212 // Add the default states. 219 213 this.states.add([ 220 214 libraryState … … 693 687 } 694 688 }); 695 689 696 }(jQuery, _, Backbone, wp)); 697 No newline at end of file 690 }(jQuery, _, Backbone, wp));