Changeset 22755
- Timestamp:
- 11/21/2012 01:05:44 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/async-upload.php
r19712 r22755 38 38 wp_die( __( 'You are not allowed to edit this item.' ) ); 39 39 40 if ( 2 == $_REQUEST['fetch'] ) { 41 add_filter('attachment_fields_to_edit', 'media_single_attachment_fields_to_edit', 10, 2); 42 echo get_media_item($id, array( 'send' => false, 'delete' => true )); 43 } else { 44 add_filter('attachment_fields_to_edit', 'media_post_single_attachment_fields_to_edit', 10, 2); 45 echo get_media_item($id); 40 switch ( $_REQUEST['fetch'] ) { 41 case 3 : 42 if ( $thumb_url = wp_get_attachment_image_src( $id, 'thumbnail', true ) ) 43 echo '<img class="pinkynail" src="' . esc_url( $thumb_url[0] ) . '" alt="" />'; 44 echo '<a class="edit-attachment" href="' . esc_url( get_edit_post_link( $id ) ) . '" target="_blank">' . _x( 'Edit', 'media item' ) . '</a>'; 45 $title = $post->post_title ? $post->post_title : wp_basename( $post->guid ); // title shouldn't ever be empty, but use filename just in cas.e 46 echo '<div class="filename new"><span class="title">' . esc_html( wp_html_excerpt( $title, 60 ) ) . '</span></div>'; 47 break; 48 case 2 : 49 add_filter('attachment_fields_to_edit', 'media_single_attachment_fields_to_edit', 10, 2); 50 echo get_media_item($id, array( 'send' => false, 'delete' => true )); 51 break; 52 default: 53 add_filter('attachment_fields_to_edit', 'media_post_single_attachment_fields_to_edit', 10, 2); 54 echo get_media_item($id); 55 break; 46 56 } 47 57 exit; -
trunk/wp-admin/css/wp-admin-rtl.css
r22723 r22755 1050 1050 } 1051 1051 1052 .media-item .edit-attachment, 1052 1053 .media-item .error-div a.dismiss, 1053 1054 .describe-toggle-on, -
trunk/wp-admin/css/wp-admin.css
r22731 r22755 3818 3818 } 3819 3819 3820 .media-item .edit-attachment, 3820 3821 .describe-toggle-on, 3821 3822 .describe-toggle-off { … … 3847 3848 #media-items { 3848 3849 width: 623px; 3850 } 3851 3852 .media-new-php #media-items { 3853 margin: 1em 0; 3849 3854 } 3850 3855 … … 5534 5539 } 5535 5540 5536 .wp-full-overlay-sidebar .wp-full-overlay-header { 5537 border-top: 0; 5538 border-bottom: 1px solid #fff; 5539 box-shadow: inset 0 -1px 0 0px #dfdfdf; 5541 .wp-full-overlay-sidebar .wp-full-overlay-header { 5542 border-top: 0; 5543 border-bottom: 1px solid #fff; 5544 box-shadow: inset 0 -1px 0 0px #dfdfdf; 5540 5545 } 5541 5546 -
trunk/wp-admin/includes/media.php
r22749 r22755 1056 1056 global $redir_tab; 1057 1057 1058 echo "<a class='toggle describe-toggle-on' href='#'>$toggle_on</a>"; 1059 1058 1060 if ( ( $attachment_id = intval( $attachment_id ) ) && $thumb_url = wp_get_attachment_image_src( $attachment_id, 'thumbnail', true ) ) 1059 1061 $thumb_url = $thumb_url[0]; 1060 1062 else 1061 1063 $thumb_url = false; 1064 1065 $display_title = ( !empty( $title ) ) ? $title : $filename; // $title shouldn't ever be empty, but just in case 1066 $display_title = $show_title ? "<div class='filename new'><span class='title'>" . wp_html_excerpt( $display_title, 60 ) . "</span></div>" : ''; 1067 1068 echo "<p><a href='$attachment_url' target='_blank'><img class='thumbnail' src='$thumb_url' alt='' /></a></p>"; 1062 1069 1063 1070 $post = get_post( $attachment_id ); -
trunk/wp-admin/media-new.php
r22752 r22755 91 91 updateMediaForm(); 92 92 post_id = 0; 93 shortform = 1;93 shortform = 3; 94 94 }); 95 95 </script> -
trunk/wp-includes/js/plupload/handlers.js
r22305 r22755 113 113 function prepareMediaItem(fileObj, serverData) { 114 114 var f = ( typeof shortform == 'undefined' ) ? 1 : 2, item = jQuery('#media-item-' + fileObj.id); 115 if ( f == 2 && shortform > 2 ) 116 f = shortform; 115 117 116 118 try { … … 430 432 } 431 433 432 if ( up.runtime == 'html4' ) 434 if ( up.runtime == 'html4' ) 433 435 $('.upload-flash-bypass').hide(); 434 436 });
Note: See TracChangeset
for help on using the changeset viewer.