0

We require our users to verify their phone numbers upon creation or number change. If there is no logged in user, they get redirected to the login page no matter what path they type into the browser.

How can I do something similar where if a user IS logged in and they're not verified, they get redirected to the verification page?

Note, we have a field on the user object called field_verified.

  • Did you try the rules module? With rules, you can use the React on event: user has logged in, add a condition data comparison, compare your field and finally add an action, redirect user. The setup would take about 2 minutes. – user11589961 Dec 6 '19 at 2:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.