S
S
Sergey Arsentiev2022-02-11 12:36:37
opencart
Sergey Arsentiev, 2022-02-11 12:36:37

How can an admin stay logged in in Opencart?

In opencart 3, the admin remains logged in for a short time, logged in as admin, subjectively half an hour passed, he logged out.
In ocstore 2.3 - the same.
And in ocstore 3, for example, it lasts forever until you log out yourself.

Is there any way to make the logged in admin in Opencart 3 and Ocstore 2.3 also last continuously?
If anyone has done this and knows, then please write.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Rst0, 2022-02-18
@Rst0

in common.js admin add

function serverPing() {
      $.ajax({ url: location.href });      // <--  добавить  до  2
   }
$(document).ready(function() {       // <-- найти эту строку   1

   setInterval('serverPing()', 30000);    // <-- добавить после   3

log in and don't close the tab

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question