I just posted a wrapper module for using UC Ajax Cart with Authcache. This allows full page caching for authenticated users while still providing users with a dynamic cart.

Here's the module in it's current form:
http://www.ubercart.org/contrib/13521

If you want to merge this code into your project, feel free. If not, no worries. I'm also going to see about adapting this to work with full page caching for anonymous users.

Comments

erik seifert’s picture

Thanks, will be in go to 2.0 Version

mikeytown2’s picture

@adamo
plans for anonymous users: #586210: Set session cookie
I would love your help & input, haven't tackled this yet, hope to do so next week.

erik seifert’s picture

Cool,

We should check this module with new version 2-ALPHA3. But the architecture is not different from 1.0 version.

adamo’s picture

I'll test it with 2.x when I get a chance. Should work fine though. It gets the cart block data by calling uc_ajax_cart_block('view'), and it adds it's own submit handler to uc_product_add_to_cart_form and uc_catalog_buy_it_now_form so it can invalidate the users browser cache when the user adds something to their cart. Those are really the only interactions with uc_ajax_cart.

Also, I forgot to mention that you need to apply a patch to Authcache (http://drupal.org/node/603700#comment-2180122) before this module will work. Otherwise the JSON it returns will get corrupted.

I just posted an updated version that will serve up dynamic carts to anonymous users as well (http://www.ubercart.org/contrib/13521) Currently you must have Authcache configured to handle caching for anonymous users or cart contents will end up getting cached.

@mikeytown2:
Not sure how much I can help. I don't use Boost. Currently this module will handle dynamic carts for anonymous users but it requires Authcache. It is based on the Authcache Example module by Jonah Ellison (author of Authcache) and he is the brains behind all the AJAX and session cookie handling stuff. If you have questions about anything this module does I'll do my best to answer them.

erik seifert’s picture

it adds it's own submit handler to uc_product_add_to_cart_form and uc_catalog_buy_it_now_form

This could be a problem because JavaScript has changed. Or mean you a "#submit" function ?

adamo’s picture

That's what I meant, a "#submit" function.

stewart.adam’s picture

Status: Active » Fixed

Ubercart broke their contrib links and this is rather old issue, so I'm going to mark it as closed. I recently inherited this module from the previous maintainer and without the wrapper module I cannot personally confirm it has been merged into 6.x-2.x but I will assume so based on the comments above... If not please let me know (and provide and updated link to the wrapper)! Thanks.

Status: Fixed » Closed (fixed)

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