Changeset 11749 for trunk/wp-admin/includes/media.php
- Timestamp:
- 07/30/2009 01:39:34 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/media.php
r11704 r11749 1167 1167 ); 1168 1168 1169 $delete_href = wp_nonce_url("post.php?action= delete-post&post=$attachment_id", 'delete-post_' . $attachment_id);1169 $delete_href = wp_nonce_url("post.php?action=trash&post=$attachment_id", 'delete-post_' . $attachment_id); 1170 1170 if ( $send ) 1171 1171 $send = "<input type='submit' class='button' name='send[$attachment_id]' value='" . esc_attr__( 'Insert into Post' ) . "' />"; 1172 1172 if ( $delete ) 1173 $delete = "<a href=\" #\" class=\"del-link\" onclick=\"document.getElementById('del_attachment_$attachment_id').style.display='block';return false;\">" . __('Delete') . "</a>";1173 $delete = "<a href=\"$delete_href\" id=\"del[$attachment_id]\" class=\"delete\">" . __('Move to Trash') . "</a>"; 1174 1174 if ( ( $send || $delete ) && !isset($form_fields['buttons']) ) 1175 $form_fields['buttons'] = array('tr' => "\t\t<tr class='submit'><td></td><td class='savesend'>$send $delete 1176 <div id=\"del_attachment_$attachment_id\" class=\"del-attachment\" style=\"display:none;\">" . sprintf(__("You are about to delete <strong>%s</strong>."), $filename) . " <a href=\"$delete_href\" id=\"del[$attachment_id]\" class=\"delete\">" . __('Continue') . "</a> 1177 <a href=\"#\" class=\"del-link\" onclick=\"this.parentNode.style.display='none';return false;\">" . __('Cancel') . "</a></div></td></tr>\n"); 1175 $form_fields['buttons'] = array('tr' => "\t\t<tr class='submit'><td></td><td class='savesend'>$send $delete</td></tr>\n"); 1178 1176 1179 1177 $hidden_fields = array();
Note: See TracChangeset
for help on using the changeset viewer.