Welcome Guest, Not a member yet? Register   Sign In
Shield Common Code to Detect Force Password Reset
#1

Hi,
Just looking for som eguidance as to where to detect if a Force Password Reset has been requested.
I'd like this to be on EVERY page, so that no matter where a user is, when a force password reset is set, they are redirected to the change password form we have.
Can someone please give me some guidance as to where to add some code to detect this before every page is rendered (except password reset / login / logout)
Reply
#2

See https://shield.codeigniter.com/reference...word-reset
Reply
#3

Thanks for this - I want to do some other bespoke things as well.

Still need to work out where to put code that I can customise, before every page gets loaded.

Is that still something to do with Controller Filters?
Just unsure where to start with this.
Reply
#4

(05-05-2024, 06:16 AM)bmmcito Wrote: Thanks for this - I want to do some other bespoke things as well.

Still need to work out where to put code that I can customise, before every page gets loaded.

Is that still something to do with Controller Filters?
Just unsure where to start with this.

Controller filters have two methods defined. One runs before a controller is instantiated, and the other one runs after. Personally, I have used the before method in a filter.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB