Forums / Templates, Stylesheets, Page Layout / Checking shopping cart info in php

Checking shopping cart info in php

Locked

Views: 1,940

Results 1 to 3 of 3
This thread is locked. New replies are disabled.
17 Jul 2006, 5:33 PM
#1
baronvoninternet avatar

baronvoninternet

New Zenner

Join Date:
Jul 2006
Posts:
4
Plugin Contributions:
0

Checking shopping cart info in php

I've been working with ZenCart for a few days now, and have got it all set up with modified templates and everything. But there are several custom things I want to do for which I don't think there exists a module (or at least, I wouldn't expect there to be as many things are very minor).

Mainly, I would like to know of an easy way to access info about the user's shopping cart from PHP, but I couldn't find anything obvious. One specific task, for example, is if the user has more than $200 worth of items in their shopping cart, I need to display a link to a pdf document the user must fill out and fax in before their item can be shipped. So for that, I would just need some variable like $ORDER_TOTAL to check and then take whatever action based on that. When I searched for "TOTAL" in the code, to try to find some value that may be set by ZenCart, I came up with a bunch of MODULE_ORDER_TOTAL things that didn't seem to relate (but I could easily be wrong).

Another useful piece of info would be how many items the user has in the cart.

Can someone point me in the right direction? Even if there's not a simple one-step way of finding this information, I can do whatever queries/calculations need to be done as long as I know where to look to get started.

Thanks!

17 Jul 2006, 11:20 PM
#2
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,664
Plugin Contributions:
0

Re: Checking shopping cart info in php

Does it matter where in the checkout process this Link is displayed?

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

18 Jul 2006, 12:59 PM
#3
baronvoninternet avatar

baronvoninternet

New Zenner

Join Date:
Jul 2006
Posts:
4
Plugin Contributions:
0

Re: Checking shopping cart info in php

Kim:

Does it matter where in the checkout process this Link is displayed?
I would prefer to know at all times... so I could display the link underneath the user's shopping cart, or at least the first time after they exceeded $200. At the very least, they would need to see it on the final confirmation page before they completed paying for their order.