• Resolved novawebb

    (@novawebb)


    Is it possible to list all current access levels on a user page using shortcodes?

    And having each listed access level linked to the restricted content.

Viewing 1 replies (of 1 total)
  • Plugin Author Joachim Jensen

    (@intoxstudio)

    There is currently no shortcode to list a user’s levels, but it can be done with the RUA API.

    Something like this

    
    $user = rua_get_user();
    foreach($user->level_memberships() as $user_level) {
        echo $user_level->level()->get_title() . "\n";
    }
    

    Due to the way Access Conditions are stored, it is not possible to list all content that is restricted by a given level (in a scalable way)

    I hope this helps!

Viewing 1 replies (of 1 total)

The topic ‘List current access levels’ is closed to new replies.