Support » Plugin: Restrict User Access - Membership Plugin with Force » Import Users into a category

  • Resolved bluemeansgo

    (@bluemeansgo)


    I have 960 users that I want to import and assign to specific permission levels.

    Here’s my setup.

    I have 24 Application_Centres (setup as Custom Taxonomy).
    I have 300+ Application CPTs which can belong in 1 or more Application_Centres.
    I have ~1000 Users which are assigned to one or more of the application centres.

    A user who belongs to an application centre can view all the applications inside it.

    I can create 24 Access levels ( one for each Application_Centre taxonomy ) but I really don’t want to go through 1000+ users and assign them one-by-one to each centre. Most only are assigned to one application centre.

    So, is there a good way to batch assign these? How is the data stored in the WP database?

    Side note. If someone doesn’t have access to an application centre, I’d prefer it if they couldn’t see it at all. What’s the best way to do this?

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

    (@intoxstudio)

    If your users already have distinct roles, then you can synchronize each level to that role. If not, then currently the only way to “batch assign” a level to a list of users is by using the API: rua_add_user_level($user_id:int,$level_id:int)

    Right now membership data is stored in wp_usermeta: the level ID itself and a date for when it was given to the user.

    Do you mean that you don’t want the application centre to show up anywhere on the site, eg. in widgets, custom lists and so on? Currently the plugin does not support restricting these items out-of-the-box, but for widgets you could use the plugin Content Aware Sidebars (also developed by me) to hide sidebars and widgets for certain levels.

Viewing 1 replies (of 1 total)
  • The topic ‘Import Users into a category’ is closed to new replies.