Terms list table: Only show 'View' links for public taxonomies. props SergeyBiryukov. fixes #24692.
git-svn-id: https://develop.svn.wordpress.org/trunk@24824 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f05e592506
commit
438002864f
@ -259,7 +259,8 @@ class WP_Terms_List_Table extends WP_List_Table {
|
|||||||
}
|
}
|
||||||
if ( current_user_can( $tax->cap->delete_terms ) && $tag->term_id != $default_term )
|
if ( current_user_can( $tax->cap->delete_terms ) && $tag->term_id != $default_term )
|
||||||
$actions['delete'] = "<a class='delete-tag' href='" . wp_nonce_url( "edit-tags.php?action=delete&taxonomy=$taxonomy&tag_ID=$tag->term_id", 'delete-tag_' . $tag->term_id ) . "'>" . __( 'Delete' ) . "</a>";
|
$actions['delete'] = "<a class='delete-tag' href='" . wp_nonce_url( "edit-tags.php?action=delete&taxonomy=$taxonomy&tag_ID=$tag->term_id", 'delete-tag_' . $tag->term_id ) . "'>" . __( 'Delete' ) . "</a>";
|
||||||
$actions['view'] = '<a href="' . get_term_link( $tag ) . '">' . __( 'View' ) . '</a>';
|
if ( $tax->public )
|
||||||
|
$actions['view'] = '<a href="' . get_term_link( $tag ) . '">' . __( 'View' ) . '</a>';
|
||||||
|
|
||||||
$actions = apply_filters( 'tag_row_actions', $actions, $tag );
|
$actions = apply_filters( 'tag_row_actions', $actions, $tag );
|
||||||
$actions = apply_filters( "{$taxonomy}_row_actions", $actions, $tag );
|
$actions = apply_filters( "{$taxonomy}_row_actions", $actions, $tag );
|
||||||
|
Loading…
Reference in New Issue
Block a user