Created
June 12, 2021 21:43
-
-
Save chrispian/7e4e573613c568194851770aca5af451 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function custom_remove_post_row_actions( $actions ) { | |
// You could check the post type or users here to only do this under certain conditions. | |
unset( $actions['trash'] ); | |
return $actions; | |
} | |
add_filter( 'post_row_actions', 'custom_remove_post_row_actions', 10, 1 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment