I forgot to mention that I want to keep the current user logged in - also when the user is not in the backoffice. I have the following scenario:
1) The user logs in to Umbraco 7
2) The user navigates to a node
3) The user clicks my custom action which results in a redirect to a page outside the backoffice (much like the preview)
4) The user works in my custom context for a while
5) The user returns to the backoffice and continues his/her work
If the user stays in the custom context 4) for a long time the session is lost and the user is no longer authenticated. Is there a method I can call, that can keep the authentication alive?
I was fooled by the Umbraco backoffice which changes to the login screen after the getremainingseconds... call returns less the 30 no mater if the current user is still authenticated or not.
How to actively keep session alive
Hi,
Is it possible to keep the session alive by making an ajax call? If yes which call should I make?
I've tried to make my own API method but my session still dies.
Any input?
Cheers Joachim
I belive the back end (at least in v6) calls ping.aspx - /umbraco/ping.aspx
https://github.com/umbraco/Umbraco-CMS/blob/b3f6a8c71bdd84e874f0b643373cbbe1aec2fd90/src/Umbraco.Web/umbraco.presentation/keepAliveService.cs
not sure if that helps/
I forgot to mention that I want to keep the current user logged in - also when the user is not in the backoffice. I have the following scenario:
1) The user logs in to Umbraco 7
2) The user navigates to a node
3) The user clicks my custom action which results in a redirect to a page outside the backoffice (much like the preview)
4) The user works in my custom context for a while
5) The user returns to the backoffice and continues his/her work
If the user stays in the custom context 4) for a long time the session is lost and the user is no longer authenticated. Is there a method I can call, that can keep the authentication alive?
Cheers Joachim
My bad, it actually works as I intended it.
I was fooled by the Umbraco backoffice which changes to the login screen after the getremainingseconds... call returns less the 30 no mater if the current user is still authenticated or not.
Sorry for the noise . . .
/Joachim
is working on a reply...