Jump to content
helenisonfire

Back Office automatically logs out

Recommended Posts

Hello. I have installed the latest version of Prestashop, but whenever I click on certain features in the Back Office like the modules, it just logs out for no reason.

I have been reading about this issue and it seems to have something to do with the cookies, so apparently I have to go to Advanced Parameters-> Admin and set the option "check cookie IP" to NO. The problem is, I have already tried that but it logs out when I try to save the change.

Other things I have already tried have been: uninstall and reinstall the whole prestashop on my server, and changing the file classes/Cookies.php by comenting the line that you can see strikethrough:

if ($this->id_employee AND Validate::isUnsignedId($this->id_employee) AND Employee::checkPassword(intval($this->id_employee), $this->passwd)

//AND (!isset($this->_content[‘remote_addr’]) OR $this->_content[‘remote_addr’] == ip2long(Tools::getRemoteAddr()))).

None of this options have worked.

Can anybody please help me? I am desperate to solve this, have been working on the problem for hours and still not getting a clue on how to solve it 

 

 

 

Share this post


Link to post
Share on other sites

UPDATE: I have tried this new idea that i found on stack overflow:

The problem was from the « Check the IP address on the cookie » parameter set to « yes ». Since i was locked out from admin and could not change it, i did it directly in the database with this SQL request :

UPDATE ps_configuration SET value = 0 WHERE name='PS_COOKIE_CHECKIP';

This actually solves the problem with the cookies checking the IP address, now it's set to "NO", but hasn't solved my problem. 

 

Anybody has an idea of what else it could be?

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More