I have got the cart up and working and I have been able to integrate my payment gateway's iFrame setup just fine.
Once I receive a response from my processor (ether transaction approved or transaction decline) I need to send an email if approved to the customer about their purchase. I have the email all set and is sending but I can not figure out how to print the item and the quantity in the email.
Exp of mail output:
Amount (in USD):
Item(s):
First Name:
Last Name:
Company Name:
Address:
Address2:
Country:
Post Code/Zip:
City:
Email:
I figure that what I need to do is take this bit of code
- Code: Select all
foreach ($cart->get_contents() as $item)
{
$message .= 'Item: ' . $item['name'];
$message .= "\nPrice: " . $item['price'];
$message .= "\nQuantity: " . $item['qty'];
$message .= "\n\n";
}
and turn $item['name'] into $_SESSION['item'] etc....but I can not figure out how or where I can do this so that it carries from the jCart pages to the iFrame page then to my email function....any ideas or guidance would be great!
Oh and I have read and tried the "HOW TO: Modify jCart to send an email to the merchant" here in the FAQ and yes it would be perfect if I was using paypal or if I was sending the email before I get the response from my processor.
Thanks
Frosy
