Hi and thanks for a great module!

The module works beautifully for authenticated users, but it doesn't for anonymous users. When you're adding something to a cart as anonymous user - "Empty cart" message still persists after page reload. But the anonymous cart is existing and visible in the admin section in "Shopping Carts" tab.

Main modules I've installed:
-authcache
-filecache
-commerce
-commerce_authcache

Please, try to reproduce the problem and see if it works for you. Thanks!

Comments

wadmiraal’s picture

Status: Active » Postponed (maintainer needs more info)

That's strange. I cannot reproduce this behavior. It works for me with anonymous carts (several anonymous users at once, all carts are different and correct for each user/session).

Did you try emptying your browser cache ? Force-reloading the page ?

jount’s picture

It worked for me after disabling authcache debug mode.

I've been looking to php backtrace, and noticed that drupal_goto() was called with drupal_exit() after adding a product to cart, and "headers already sent" error appeared in Drupal logs. It seems anonymous session was not started because debug headers were sent from authcache on hook_exit. But I'm not 100% sure about it.

After disabling authcache's debug mode, everything worked for me. Hope this information will help people, who experience similar problem.

And thanks again for a great module!

P.S. For future UX improvement of the module - I think it would be great to have some ajax throbber indicating that cart block is currently loading.

wadmiraal’s picture

Status: Postponed (maintainer needs more info) » Closed (works as designed)

Thanks for the information. This will certainly help other people as well.

As for the throbber, I fully agree. That's why I added a CSS class to the container while the AJAX request is made ;-). I do not want to add any styles or graphics to this module - I want it to be purely functional code. The class is "commerce-authcache-target". The div with this class will be replaced with the cart content. So you can add a throbber to the div background using CSS. It will disapear as soon as the content is replaced.

wadmiraal’s picture

Status: Closed (works as designed) » Reviewed & tested by the community

Changing the status so other users with a similar problem find this.

Answer is in #2

wadmiraal’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

fixed typos

WillowDigit’s picture

Issue summary: View changes

I am experiencing a slightly different yet related problem. Refer to Tutorial: Commerce Kickstart 2 and Authcache 2 to Mario Baron's problem.

' if the user visited a few pages before adding a product to cart if for whatever reason that user leaves the cart and returns to one of the pages previously visited the shopping cart view will return the "Shopping cart empty" value even thou there is an item inside the shopping cart.'

He did not install Commerce Authcache, yet I did hoping it would solve that issue, yet it did not.
I have enabled the modules as per the tutorial referred to. Using Drupal 7.28, commerce_kickstart-7.x-2.14, Authcache 7.x-2.0-beta3, and Commerce Authcache 7.x-1.0-beta1+0-dev.

IckZ’s picture

I've the same Problem as WillowDigit. I've also enabled the same modules as he did. Can anyone confirm a bug or is this such a missing setting or anything else?