Plugin to auto assign users to spaces based on WordPress roles
I've created a plugin that automatically adds users to spaces based on role/space mappings. We need this functionality for a private member site I'm working on. I've read that you can do something similar using FluentCRM but I am reluctant to install another big plugin just for that functionality so I created this new small plugin. Most of the code came from ChatGPT except for the FC specific parts so if the code looks bad, blame ChatGPT (also if it crashes your website, blame ChatGPT :). Install and use at your own risk.
A FluentCommunity Sync settings page gets added to the WordPress settings menu. This page lets you add or remove role/space mappings. You can select multiple spaces for each role.
Hopefully this is helpful for some of you. If you have any problems, let me know. However, be warned that I created this for my specific use case so it may not get updated beyond the version I'm linking below.
Link: fc-roles-link.zip
Very cool! I'm using Suretriggers (now called Ottokit) for this functionality. I completely understand why you created a tiny plugin to achieve this functionality.
