0

I have made a component where it is tedious when the session ends after 15 or 30 minutes and you have to log in again. For all other pages, however, this time is fine.

Is there a way to temporarily change this duration as soon as you get to this page or call up this component in the frontend area?

I've already googled it, but haven't found any good results. I know that you can also adjust this value in general. However, this is not the solution in my case.

Does anyone have a solution for this?

1 Answer 1

2

On HTML pages you can use Keepalive script which periodically makes AJAX requests to prevent session expiration. It's widely used across the CMS on form pages. Usage in view layout:

$this->document->getWebAssetManager()->useScript('keepalive');

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.