Ticket #11673: 11673-against-2.9-branch.diff
File 11673-against-2.9-branch.diff, 2.9 KB (added by , 15 years ago) |
---|
-
edit-attachment-rows.php
96 96 $actions['untrash'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=untrash&post=$post->ID", 'untrash-post_' . $post->ID) . "'>" . __('Restore') . "</a>"; 97 97 elseif ( EMPTY_TRASH_DAYS && MEDIA_TRASH ) 98 98 $actions['trash'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=trash&post=$post->ID", 'trash-post_' . $post->ID) . "'>" . __('Trash') . "</a>"; 99 if ( $is_trash || !EMPTY_TRASH_DAYS || !MEDIA_TRASH ) 100 $actions['delete'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=delete&post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>"; 99 if ( $is_trash || !EMPTY_TRASH_DAYS || !MEDIA_TRASH ) { 100 $delete_ays = (!$is_trash && !MEDIA_TRASH) ? " onclick='return showNotice.warn();'" : ''; 101 $actions['delete'] = "<a class='submitdelete'$delete_ays href='" . wp_nonce_url("post.php?action=delete&post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>"; 102 } 101 103 } 102 104 if ( !$is_trash ) 103 105 $actions['view'] = '<a href="' . get_permalink($post->ID) . '" title="' . esc_attr(sprintf(__('View “%s”'), $title)) . '" rel="permalink">' . __('View') . '</a>'; -
upload.php
392 392 if ( current_user_can('edit_post', $post->ID) ) 393 393 $actions['edit'] = '<a href="' . get_edit_post_link($post->ID, true) . '">' . __('Edit') . '</a>'; 394 394 if ( current_user_can('delete_post', $post->ID) ) 395 if ( EMPTY_TRASH_DAYS && MEDIA_TRASH ) 395 if ( EMPTY_TRASH_DAYS && MEDIA_TRASH ) { 396 396 $actions['trash'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=trash&post=$post->ID", 'trash-post_' . $post->ID) . "'>" . __('Trash') . "</a>"; 397 else 398 $actions['delete'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=delete&post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>"; 397 } else { 398 $delete_ays = !MEDIA_TRASH ? " onclick='return showNotice.warn();'" : ''; 399 $actions['delete'] = "<a class='submitdelete'$delete_ays href='" . wp_nonce_url("post.php?action=delete&post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>"; 400 } 399 401 $actions['view'] = '<a href="' . get_permalink($post->ID) . '" title="' . esc_attr(sprintf(__('View “%s”'), $title)) . '" rel="permalink">' . __('View') . '</a>'; 400 402 if ( current_user_can('edit_post', $post->ID) ) 401 403 $actions['attach'] = '<a href="#the-list" onclick="findPosts.open(\'media[]\',\''.$post->ID.'\');return false;" class="hide-if-no-js">'.__('Attach').'</a>';