2

I want to keep track of all items added to uber cart. I.e. Whenever someone clicks ADD TO CART, I want to: create a database entry of the time and item added.

This way I can see which items are most clicked on.

The logic to add it to a db etc is easy to do. What I need to know is, how do I plug into the "add to cart" part. I.e. How do I know when this has been clicked?

rockstardev
  • 13,479
  • 39
  • 164
  • 296

2 Answers2

2

You should be able to implement hook_add_to_cart in a custom module, which will get called exactly as you describe above.

jhedstrom
  • 3,378
  • 1
  • 23
  • 19
0

In Drupal 7 it changed to hook_uc_add_to_cart