Add Delete link link to edit link form. Props mdawaffe. fixes #6126

git-svn-id: https://develop.svn.wordpress.org/trunk@7198 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-03-10 05:48:28 +00:00
parent a2a407faf4
commit a73cfe0479
1 changed files with 4 additions and 0 deletions

View File

@ -53,6 +53,10 @@ function xfn_check($class, $value = '', $deprecated = '') {
<p class="submit">
<input type="submit" class="button" name="save" value="<?php _e('Save'); ?>" style="font-weight: bold;" tabindex="4" />
<?php
if ( ( 'edit' == $action) && current_user_can('manage_links') )
echo "<a class='submitdelete' href='" . wp_nonce_url("link.php?action=delete&amp;link_id=$link_id", 'delete-bookmark_' . $link_id) . "' onclick=\"if ( confirm('" . js_escape( sprintf( __("You are about to delete this link '%s'\n'Cancel' to stop, 'OK' to delete."), $link->link_name )) . "') ) { return true;}return false;\">" . __('Delete&nbsp;link') . "</a>";
?>
</p>
<div class="side-info">