WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to adjust the comments screen for non admins to my project. Right now I'd like to disable

Quick Edit | Edit | History | Spam

under any comment left for any post created by the user.


share|improve this question
up vote 1 down vote accepted

This is done filtering the *_row_actions.
For the Comments screen (/wp-admin/edit-comments.php) this is the hook:

add_filter( 'comment_row_actions', 'comments_row_wpse_92313', 15, 2 );

function comments_row_wpse_92313( $actions, $comment )
    if( !current_user_can( 'delete_plugins' ) )
        unset( $actions['quickedit'], $actions['edit'], $actions['spam'] );

    return $actions;

I cannot see a History option, maybe it's included by some plugin (?). It's a matter of adding it to the unset list.
These are the default actions in the core files:

$actions = array(
    'approve' => '', 
    'unapprove' => '',
    'reply' => '',
    'quickedit' => '',
    'edit' => '',
    'spam' => '', 
    'unspam' => '',
    'trash' => '', 
    'untrash' => '', 
    'delete' => ''
share|improve this answer
It works like a charm! Thanks! – user27309 Mar 26 '13 at 8:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.