mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-02 05:31:25 +01:00
Deletion link should always show
git-svn-id: http://svn.automattic.com/wordpress/trunk@13905 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
db03ca0c13
commit
fb96ce358a
@ -195,13 +195,13 @@ if ( $can_publish ) : // Contributors don't get to choose the date of publish ?>
|
|||||||
<?php
|
<?php
|
||||||
if ( current_user_can( "delete_post", $post->ID ) ) {
|
if ( current_user_can( "delete_post", $post->ID ) ) {
|
||||||
if ( !EMPTY_TRASH_DAYS ) {
|
if ( !EMPTY_TRASH_DAYS ) {
|
||||||
$delete_url = wp_nonce_url( add_query_arg( array('action' => 'delete', 'post' => $post->ID) ), "delete-${post_type}_{$post->ID}" );
|
$delete_url = wp_nonce_url( add_query_arg( array('action' => 'delete', 'post' => $post->ID), admin_url( 'post.php' ) ), "delete-${post_type}_{$post->ID}" );
|
||||||
$delete_text = __('Delete Permanently');
|
$delete_text = __('Delete Permanently');
|
||||||
} else {
|
} else {
|
||||||
$delete_url = wp_nonce_url( add_query_arg( array('action' => 'trash', 'post' => $post->ID) ), "trash-${post_type}_{$post->ID}" );
|
$delete_url = wp_nonce_url( add_query_arg( array('action' => 'trash', 'post' => $post->ID), admin_url( 'post.php' ) ), "trash-${post_type}_{$post->ID}" );
|
||||||
$delete_text = __('Move to Trash');
|
$delete_text = __('Move to Trash');
|
||||||
} ?>
|
} ?>
|
||||||
<a class="submitdelete deletion<?php if ( 'edit' != $action ) { echo " hidden"; } ?>" href="<?php echo $delete_url; ?>"><?php echo $delete_text; ?></a><?php
|
<a class="submitdelete deletion" href="<?php echo $delete_url; ?>"><?php echo $delete_text; ?></a><?php
|
||||||
} ?>
|
} ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user