Which PayPal module are you using, and why?
Which PayPal module are you using, and why?
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
PayPal IPN - Website Payments Standard
If you were to use the more contemporary PayPal Express Checkout module instead of the older Website Payments Standard, you would already be getting the Transaction ID number in your admin emails, since at least v1.3.9a anyway.
The first line of the admin-copy of the email will show it, like this:TransID: 2G49759770491990A
Order Confirmation from [Store name here]
[Customer name here]
Thanks for shopping with us today!
The following are the details of your order.
------------------------------------------------------
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Or, if you insist on using the less reliable Website Payments Standard module, you'd have to hack in the following to make the same thing happen with it:
Again, this is based on v1.3.9h:
/ipn_main_handler.php
line 352, add the new line as highlighted here:andCode:$_SESSION['order_number_created'] = $insert_id; $GLOBALS[$_SESSION['payment']]->transaction_id = $_POST['txn_id'];
/includes/modules/payment/paypal.php
line 596, add the new highlighted line as shown:Code:$PDTstatus = ($pdtTXN_is_unique && $PDTstatus); if ($PDTstatus == TRUE) $this->transaction_id = $this->pdtData['txn_id']; return $PDTstatus;
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Well, Im running 1.38, and my ipn_main_handler.php file doesnt even have 352 lines in it, let alone the line..
$_SESSION['order_number_created'] = $insert_id;
Notwithstanding that I firmly believe you should be upgrading ASAP, try putting that line after this one instead:Code:$order->create_add_products($insert_id, 2);
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Perfect, thanks for your help![]()