Support Forum

User group change not permanent

SZ Stefan Zabel
Stefan Zabel
Member

Hi, I’m trying to move someone to the moderator user group. It seems to work, then something happens and they move back to the original user group. It might be when they log back in, I cannot work it out.

Sometimes I see them in the moderator list at the bottom of the forum – see attachment – sometimes I don’t, but when they do appear there, they soon disappear again. Can you help? Thanksmod-list.JPG

12 Answers

New Answer

SZ Stefan Zabel
Stefan Zabel
Member

We use Wishlist Member. Each Wishlist member level has a WP role attached to it which is associated with a specific user group in Simple Press.

I’m thinking when the newly assigned moderator logs in again, the role associated with their Wishlist membership tells SP they need to be moved back to the user group associated with the role that’s associated with their member level, if you see what I mean.

Other than setting up a whole new member level for them, do you know a way to stop this happening, if indeed this is the issue? Thanks

YS Yellow Swordfish
Yellow Swordfish
Member

I don’t think either of those two scenarios are likely – either when they log back on – or – being influenced by the WP role.

Let’s get the obvious question out of the way first. Are you using any caching plugin – which could cause the appearance of this behaviour even if not the fact of it.

SZ Stefan Zabel
Stefan Zabel
Member

No caching plugins.

When we set up Wishlist and Simple Press, we couldn’t get the role and therefore the SP permissions to update when a subscriber changed member level. A few people had written plugins to support the integration but they didn’t work in full either. We got someone to write us a basic plugin that solved the problem, code attached in a text file below.

This might be a factor. I don’t know if WL/SP has moved on in terms of integration. Perhaps we don’t need it any more?

I also was looking at your help text on the page Forum > User Groups > Map Users to User Group, specifically the option ‘Users are limited to single usergroup membership’ which we have ticked. I didn’t understand it fully, but it mentions membership plugins and problems associated with this option:

“Please note that auto usergroup membership by WP role or by forum rank may conflict or overwrite any manual usergroup memberships (such as moderator) you may set if you have single usergroup membership set”

Is that the culprit?

YS Yellow Swordfish
Yellow Swordfish
Member

Ah – I was indeed incorrect. Your custom plugin is, indeed, checking the users role at each and every page load and changing if necessary according to the rules – like being allowed only in a single user group at a time. Checking on every page load is a bit expensive and it would have made much more sense to check on login as you, yourself, suggest.

The code in the plugin is very specific about user groups as well. It caters for 3 user groups by name which leaves it a bit inflexible. And yes – I see it can change a users group if necessary.

If you want to allow a user to be in multiple user groups you will need to change the custom plugin code. If you create a new role in WishList of ‘moderator’ and continue to allow users to be in a single SP user group then I think the plugin code would allow that as it is unaware of that WP role.

SZ Stefan Zabel
Stefan Zabel
Member

I’ve created a new role for moderator. But when I change the role for the user to moderator, WP immediately changes their role to the one associated with their Wishlist membership level.

I’ve deactivated the custom plugin, but it still happens.

Can you think of what I might be doing wrong?

I can create a new moderator membership level in WL associated with the moderator role but it’s a bit cumbersome.

YS Yellow Swordfish
Yellow Swordfish
Member

I am starting to hit the extent of my knowledge of WishList here sadly. We used to use it on this site (but @mr-papa did all of our user management maintenance and coding) and changed last year partly because we found it so inflexible and obstinate. He will be around later and may well have something to add to this thread.

This sounds like something WishList is doing to me so perhaps you do need to create this whole new group through WishList User, WP Role and then SP User Group. Unless you can determine if there are options within WishList to stop the behaviour.

YS Yellow Swordfish
Yellow Swordfish
Member

By the way – I don’t know if it is of any help, but we do have an FAQ of how we set up WL and SP to work:

https://simple-press.com/documentation/codex/faq/how-to/how-to-configure-simple-press-with-membership-plugin/

SZ Stefan Zabel
Stefan Zabel
Member

Wishlist isn’t very flexible as far as I can see either, so went with new WL moderator member level > new WP role > mapped to moderator user group in SP.

It works fine, just a pain to have another level to manage in WL.

Thanks for the advice.

YS Yellow Swordfish
Yellow Swordfish
Member

Good you are getting what you want there but yes – I grew to really dislike WishList personally although I think Steve still had a lot of time for it.
You should get that small custom plugin fixed up as it is most inefficient as it is I am afraid.

MP Mr Papa
Mr Papa
Member

wishlist was very limited… havent used in year or two…

but it works well for new members and getting the right wp role and the right simple press user group…

but sucks at memberships expiring…  it keeps members in the same wishlist group and thus the same wp role…

so we ended up have to hook into the wishlist member adding, removing, deleting, etc and then add the user to the wp role and sp usergroup manually…  worked well, but we had to have custom plugin to work…

SZ Stefan Zabel
Stefan Zabel
Member

Well, I’m glad it wasn’t just me not getting the Wishlist integration right. We had a similar problem…when our members changed Wishlist member levels, we couldn’t get the wp roles and therefore their sp usergroup to update.

Thanks for the feedback.