Hi all,
i have exactly this scenario, i want to redirect the user to the same page when a session timeout occurred or to a specific page while accessing using a direct link after being redirected to login screen.
Indeed as Pedro said, the querystring parameters are only lost when it happens on button click. Is there any workarround for this? Any other way to get GetExceptionURL() always with parameteres?
Thanks
Hi,
This is an old thread, but since there is still no answer here I'll share what we did just the other day, when asked the same question.
I'm not aware of a way to get the full URL from GetExceptionURL(), when a Security Exception is thrown because a user interacts with a screen after its session has expired.
But the following pattern can be used to get the full URL where the exception occurred, to be used to redirect the user back after a new Login:
The animation below shows the pattern at work on the sample espace that's attached:
I hope this will be helpful to someone.
Thanks! I will check it out.
In the meantime we didn't solve the problem, and just redirect to a Home Page in this situation. The flow is as follows
1. HomePage
2. Page1?context=xxx. Parameter context is filled, so it's ok.
3. (session expires)
4. User clicks button -> Security Exception -> Login and redirect to Page1
5. Page1 doesn't receive context parameter -> Redirect to HomePage
I think this sample eSpace replicates that scenario, so I expect you to be able to use this pattern to do what you wanted and redirect the user back to screen with the full parameters context.
Let me know if it worked for you.
Gonçalo Fonseca wrote:
Hi Gonçalo,
I had the same problem, and I would like to thank you for the solution that you described, with an excellent example. This solution solves my problem. Good job!Tks.Breno