BiologicalRecordsCentre / UKBMS-online

Issue tracking for UKBMS online recording site
2 stars 0 forks source link

Prompt user to login when following links to restricted access pages #203

Closed MeganLowe closed 2 years ago

MeganLowe commented 3 years ago

Hi, we have a link on the Wider Countryside Butterfly Survey page that directs people to 'Enter your Count' which links to: https://ukbms.org/my-walks This works fine when the user is already logged in, but if not logged in it takes the user to the home page. Is it possible to prompt the user to login instead? Likely to be more examples of this where there are links to pages that the user needs to be logged in to be able to view. Thanks, Megan

Gary-van-Breda commented 2 years ago

Note to self: deploy https://www.drupal.org/project/r4032login ?

Gary-van-Breda commented 2 years ago

r4032login deployed and enabled on Test for review ( https://test-brc-ukbms.pantheonsite.io/my-walks ). If a user is not logged in, and an attempt is made to access any page (not just my-walks) they do not have permissions for, they are redirected to the login page, and from there back to the originally requested page.

@MeganLowe : can you confirm this does what you want? @DavidRoy : Are you OK with this?

DavidRoy commented 2 years ago

Works well for me thanks

MeganLowe commented 2 years ago

Looks great, thanks Gary

Gary-van-Breda commented 2 years ago

Deployed to Live. R4032login module enabled, checked working OK. Closing.