Thanks guys.
We plan to use CartThrob to handle e-Commerce for our client, and they have various ordering types. Some of them are physical or digital goods, and others are subscription in nature. We need the ability to manage the automatic handling of these orders in EE after the order is complete. I’m hoping to automate pieces of post-order handling so that the client’s staff doesn’t need to.
A good example would be a paid listing of sorts. We can have the user include the details of their listing (title, short description, body, URL, etc) via custom fields on the ordering page, and after CartThrob handles the order, it’s my understanding that the following file will allow us to do more after we get approval for an order from the gateway:
system/modules/cartthrob/process/cartthrob.on_authorize.php
After the order’s completed, I’d like to put rules into that file to manipulate data within EE with PHP, such as adding a new row to a channel called “listings”. There’s more to it than that, but this is probably the easiest example I can give. My end goal was to definitely NOT have PHP working directly with MySQL….for the same reason I wouldn’t want to do that in Wordpress.
If there’s a way to do this with the API(s) that I haven’t yet seen, I’m all ears. Getting this basic communication functionality down between custom PHP and EE is paramount to our being able to do more with our clients project and others later on.
I appreciate your help!
Thanks,
Will Ashworth
PS - We may also want to do some things later via cron as well, which I haven’t fully looked into, but having my PHP communicate with EE in the way we’re talking about right now will affect those types of scripts later as well. Maybe they’ll be reports, etc….not sure yet.