Custom User Roles For Access

Hello again,

On my site i have created a new field under the user database called Role.

On this role i will use text such as: NJ, MA, PA, NY, admin, NJ-Manager

I want to only allow access for example to the pages having to do with NJ to users that are NJ or admin. When i create a workflow: When page is loaded and current user’s role doesn’t contain “NJ”, it will be forwarded to block page that logs who, when and what page they are trying to access. This works great.

However when i try to add multiple roles such as: When page is loaded and current user’s role doesn’t contain “NJ” or current user’s role doesn’t contain “admin”

It stops working. am i doing something wrong here or is this a limitation with bubble.is? would i have to create specific workflows for each role individually? that seems like it will be a pain…

Hi Joseph!

I think you want to change that to an AND comparison instead of OR…

When page is loaded and current user’s role doesn’t contain “NJ” AND current user’s role doesn’t contain “admin”

Meaning, it will redirect if not NJ and not admin.

–Ken

1 Like

i will try this. i assumed AND meant they had to be NJ role AND admin role. Thank You!

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.