mark
-
5/5/2009 10:08:24 PM
RE:can i add to shopping cart using AJAX ?
an update......
I've ditched the CartItemSelector and am writing my own method using the API.
the code below adds an item into the Cart in memory but not into the database table COM_shoppingCartSKU. How do i persist this data to the database ?
ShoppingCartInfo ShoppingCart = CMS.CMSHelper.CMSContext.CurrentShoppingCart; int[] aryProductOptions = new int[2] { 14,15 }; ShoppingCart.AddShoppingCartItem(12, 99, aryProductOptions);
I also need to persist the cart data over browser sessions for anonymous users. Is there some clever kentico technique to acheive this or do i need to custom code a cookie based solution ?
|