]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/edit-attachment-rows.php
Wordpress 2.9.2-scripts
[autoinstalls/wordpress.git] / wp-admin / edit-attachment-rows.php
index eef8f0cf85e4844b0f1f1bc4d1182b9450ce9c04..1b972a9f947941f807e04f5dd7bae5dea6613f4b 100644 (file)
@@ -96,8 +96,10 @@ foreach ($posts_columns as $column_name => $column_display_name ) {
                                $actions['untrash'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=untrash&amp;post=$post->ID", 'untrash-post_' . $post->ID) . "'>" . __('Restore') . "</a>";
                        elseif ( EMPTY_TRASH_DAYS && MEDIA_TRASH )
                                $actions['trash'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=trash&amp;post=$post->ID", 'trash-post_' . $post->ID) . "'>" . __('Trash') . "</a>";
-                       if ( $is_trash || !EMPTY_TRASH_DAYS || !MEDIA_TRASH )
-                               $actions['delete'] = "<a class='submitdelete' href='" . wp_nonce_url("post.php?action=delete&amp;post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>";
+                       if ( $is_trash || !EMPTY_TRASH_DAYS || !MEDIA_TRASH ) {
+                               $delete_ays = (!$is_trash && !MEDIA_TRASH) ? " onclick='return showNotice.warn();'" : '';
+                               $actions['delete'] = "<a class='submitdelete'$delete_ays href='" . wp_nonce_url("post.php?action=delete&amp;post=$post->ID", 'delete-post_' . $post->ID) . "'>" . __('Delete Permanently') . "</a>";
+                       }
                }
                if ( !$is_trash )
                        $actions['view'] = '<a href="' . get_permalink($post->ID) . '" title="' . esc_attr(sprintf(__('View &#8220;%s&#8221;'), $title)) . '" rel="permalink">' . __('View') . '</a>';