• Resolved charlotte

    (@charlotte23)


    Hello ??

    I put that filter (below) in the functions php file but the editors still can’t flush the cache – the button isn’t there. Have I missed something?

    add_filter( ‘sgo_purge_button_capabilities’, ‘sgo_add_new_role’ );
    function sgo_add_new_role( $default_capabilities ) {
    // Allow new user role to flush cache.
    $default_capabilities[] = ‘delete_others_posts’; // For Editors.

    return $default_capabilities;
    }

Viewing 1 replies (of 1 total)
  • Plugin Author Stoyan Georgiev

    (@stoyangeorgiev)

    Hey there @charlotte23,

    The filter and user capabilities are correct. Make sure you are using ‘ instead of ‘ in the code you’ve posted like the example below.

    add_filter( 'sgo_purge_button_capabilities', 'sgo_add_new_role' );
    function sgo_add_new_role( $default_capabilities ) {
    // Allow new user role to flush cache.
    $default_capabilities[] = 'delete_others_posts'; // For Editors.
    
    return $default_capabilities;
    }

    If you have difficulties, you can provide a site URL, so we can check it out.

    Kind regards,
    Stoyan

Viewing 1 replies (of 1 total)
  • The topic ‘Editors can’t flush Cache’ is closed to new replies.