Jump to content

[SOLVED] Logout doesn't work when cache and rewrite are activated. Any 'real' fix?


Repy

Recommended Posts

Hello there.

 

I'm experiencing an annoying problem. The logout link doesn't work, it doesn't refresh the page, and after clicking it, if you load another page, looks like you're logged out, but you can just click the login link and you're logged again. No password, etc.

 

I want some fix or even a better workaroud than disabling rewriting or cache.

 

Thanks.

 

Some relevant info:

Prestashop Version: 1.4.5.1

Server information: Linux

PHP Version: 5.2.17

MySQL Version: 5.1.52

 

EDIT: Actually, not even disabling both url rewriting and cache the logout works.

Link to comment
Share on other sites

Hah! I found the problem! :)

 

It was happening because I had a mod_expires instruction on a parent directory:

 

ExpiresByType text/html "access plus 15 minutes"

 

Commenting out this line solves the issue. Now I'm gonna add a override to that instruction on the prestashop .htacces using the backend to see if what happens.

 

Moderators: Please don't delete this topic for future reference.

  • Like 2
Link to comment
Share on other sites

Gee! I managed to make it work by adding a line in the "Specific Configuration" field (Admin>Tools>Generators). However, I couldn't find anything better and I think its somewhat silly:

 

ExpiresByType text/html "access plus 0 seconds"

 

I was thinking about "none" or something less stupid, but the only working instruction is this one, i don't know the 'hardcore' alternative to the expiring time.

 

Anyways, i noticed that the default prestashop htacces already have some mod_expires instructions, now why not include an instruction that disables caching of html files, because its needed for the platform to work correctly, so it's always good to make sure.

 

Thanks.

 

EDIT: Heh! The hardcore syntax would be:

 

ExpiresByType text/html A0

 

Devs: Please include that line on the default htaccess, because it just overrides any instruction and i can't see why not. Please answer here if you've read this otherwise i'm gonna fill a bug/improvement (but i really don't think its necessary).

  • Like 3
Link to comment
Share on other sites

  • 2 weeks later...
  • 3 years later...
  • 5 months later...
  • 5 months later...

Spent 3 days looking for a solution to this same problem, on Prestashop 1.6.1.3, and found this one. The only one that really works.

 

It does solves the problem, but it turns off all prestashop cache, forcing every page to reload, and therefore, turning the site a lot slower.

 

Will keep looking for a better solution.

 

 

Nelson

Link to comment
Share on other sites

  • 3 months later...
  • 7 months later...

SEO & URL and My Account Signout Problem is arising.


 

Hello.


 


I am continuously approaching many of my module developers but i am yet to find any solution to my help.


 


When i am trying to Create a new SEO & URL, my Back office sign's out. I dont know where is the problem. but it is not creating any other SEO & URL


 


Secondly, when i am trying to login to my Prestashop front end, it tries to login to my "My Account" tab, but i can not sign out. 


 


Please advice how to fix these both issues. 


 


Serious help needed !!!  I am not aware of most technical details like most of the people on this thread are. Due to lack of know how i am yet to fix this issue.


Edited by A. Mj (see edit history)
Link to comment
Share on other sites

  • 2 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...