AleCat83 Posted March 24, 2014 Share Posted March 24, 2014 Hello, I've got a problem with prestashop 1.5.6.2 cart on top of the pages. When I add a product to the cart it correctly show on the top page cart widget. If I change page it show cart empty and to see the product I need to refresh the page. If a try to do check out, the products are correctly inside the cart. The problem seems to be related only to the cart widget on the top of the page. Someone can help me? Thank you Link to comment Share on other sites More sharing options...
NemoPS Posted March 24, 2014 Share Posted March 24, 2014 So this is what happens? Add the product via ajax, it displays Refresh the page 1st time: not displaying Refresh the page 2nd time: it displays ? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Hi, actualy it is like this: add via ajax: displaying; refresh same page: displaying; change page (for example go to homepage): not displaying refresh page: displaying; Thank you Link to comment Share on other sites More sharing options...
NemoPS Posted March 24, 2014 Share Posted March 24, 2014 uh, really weird. Can you link the site? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 hi, sure: www.supercoverz.com Link to comment Share on other sites More sharing options...
NemoPS Posted March 24, 2014 Share Posted March 24, 2014 I can't reproduce the issue, it seems to be working fine for me On which browser are you experiencing the error? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Hi, I've done some new test. It seems to happen in chrome. On firefox it seems to work correctly. Link to comment Share on other sites More sharing options...
NemoPS Posted March 24, 2014 Share Posted March 24, 2014 Weird, it works for me on chrome Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Strange, I have another problem when I delete a product in the ajax cart: if I delete a product and change page the ajax cart still show it. After refreshing the page it go away. Seems to be some cookie problem.. Thank you Link to comment Share on other sites More sharing options...
vekia Posted March 24, 2014 Share Posted March 24, 2014 maybe it's browser-cache related problem? it's worh to clear whole browser, especially: - cookies - cache also check plugins section, maybe you've got some plugin which dealing with cookies/js ? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Hi, yes, it seems to be related to chrome browser cache, but I don't know how to resolve this. I've checked and there seems to be no module installed that deal with it. Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Hi, I'v tried to disable the chrome cache in the developer tools setting and after doing so all works well. Is there a way to make it work properly also with cache or disabe the chrome cache by default? Or users with chrome will have some problems.. Link to comment Share on other sites More sharing options...
vekia Posted March 24, 2014 Share Posted March 24, 2014 don't disable cache etc. just clear it with cookies ctrl+shift+delete and "clear browsing data" Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 This resolve the problem during my test but the customers of the site that use chrome will have the same problem. Is there a way to tell the browsers to not use cache? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 24, 2014 Author Share Posted March 24, 2014 Hi, I've resolved the problem in this way: in the .htaccess file added ExpiresDefault: "access plus 1 second" in this way the browsers are forced to not use the cached version of the page. In any case this behaviour is strange, we have other 2 e-commerce prestashop same version with default values that do not show this problem in any browser. I even don't know if this work-around represents the best solution, but at the moment it seems working. Link to comment Share on other sites More sharing options...
MarcoVan Posted March 25, 2014 Share Posted March 25, 2014 Hi, For me the same problem. I am braking my head over this. Tried all browsers on mac. Clean cache, smarty cache, paypal not activated, the default theme on and off, empty cache when all pages of the webshop are closed, etc. Sometimes it works for a little bit but than again I have the same problem. In all other posts there are some ideas but none of them help me permanent. I am getting desperate :-( PS 1.5.6.2 updated from 1.4.9 Theme Alysum Cheers Link to comment Share on other sites More sharing options...
AleCat83 Posted March 25, 2014 Author Share Posted March 25, 2014 Hi MarcoVan, have you tried my workaround? To me it seems to work. Link to comment Share on other sites More sharing options...
MarcoVan Posted March 25, 2014 Share Posted March 25, 2014 I just saw something in my apache error log that is very interesting: [Tue Mar 25 11:55:28 2014] [error] [client 66.249.76.143] PHP Notice: Undefined index: productPriceWithoutRedution in /home/xxx/domains/xxxxxxxxxxxxxxxx.nl/public_html/cache/smarty/compile/62/ae/18/62ae18cd547478bbe7dcf7c76c0a0de55de3e9fb.file.product.tpl.php on line 1130 This is coming back every time I try to buy something! If I go and look where this folder 62 is, its not there. Is he trying to call something that is not there anymore? Hi MarcoVan, have you tried my workaround? To me it seems to work. Tried that but no luck. I am not sure if I put it ok in htaccess: <ifModule mod_expires.c> ExpiresDefault "access plus 1 seconds" </ifModule> Is this right? Link to comment Share on other sites More sharing options...
AleCat83 Posted March 25, 2014 Author Share Posted March 25, 2014 Well I've put it in the .htaccess without the <ifModule mod_expires.c></ifModule> I don't know if it is correct but I've used only: ExpiresDefault "access plus 1 seconds" Link to comment Share on other sites More sharing options...
MarcoVan Posted March 25, 2014 Share Posted March 25, 2014 On the laptop at home it does work. So I can't test it here. But anyway, I would like to know what is causing the error. Can you take a look at your apache error logs? Maybe there are some answers that hit both of us? Can you place your whole htaccess file here? I now see the folder that I talked about earlier. Maybe I was not looking at the right place. I am seeing things flying after a long time looking at the screen :-). Maybe some moderator can tell me what the cache file is telling me? Cheers Link to comment Share on other sites More sharing options...
Recommended Posts