WordPress / Learn

WordPress.org Learn - The canonical source for the code and content behind https://learn.WordPress.org
237 stars 83 forks source link

Adding custom user roles using a WordPress plugin #2300

Open digitalchild opened 3 months ago

digitalchild commented 3 months ago

Details

Learning Objectives

Related Resources and Other Notes

Automation Code

digitalchild commented 3 months ago

//lessons

github-actions[bot] commented 3 months ago

Lesson Development Checklist

westnz commented 1 week ago

https://github.com/WordPress/Learn/assets/89751452/d2e8a58e-b92f-481f-9896-4cee2252e98b

digitalchild commented 1 week ago

Nice overview @westnz

Tutorial/Lessons Review Checklist

Please tick all items you've confirmed:

ironnysh commented 1 week ago

Tutorial/Lessons Review Checklist

Great lesson, @westnz.

Follow-up to @digitalchild's comments:

  1. I would say making changes to roles with any plugin, the changes are saved and need to be reverted. It's recommended if you need to make changes to a default role to copy the role and make the changes in the new role.

    There's a disclaimer on Members's documentation page:

    Any changes you make to users and roles using this feature are permanent changes. This means that if you deactivate or uninstall this plugin, the changes won’t revert to their previous state. This plugin merely provides a user interface for you to make changes directly to your WordPress database. Please use this feature wisely.

    FWIW, the revert/reset issue also came up in one of User Role Editor's support tickets.

  2. Is it relevant to mention that you can create a membership site when the lesson is about roles?

    A membership site is one of the use cases mentioned at 0:44, so it's not entirely out of the blue :-)

westnz commented 1 week ago

Really appreciate the solid feedback @digitalchild and @ironnysh