Hi,
I'm sheepishly trying to hack my way out of a bug when using the ecommerce paypal module with the pay-per-node module.
I need to get the transaction ID that is returned to ecommerce for use in the pay-per-node module, so I can do a quick database querry to get the UID for the user submitting the order, as the global $user doesn't seem to be set with the IPN happens via paypal, I suspect because of the leaving of the site to go to paypal for the time being.
Regardless, I'm trying to figure out how I can access to that value.
From the paypal.module, the function paypal_ipn() sets the value thusly:
$txnid = substr($value, strlen('txnid_'));
I need access to this value in the pay-per-node modules paypernode_productapi function, specifically in:
case 'on payment completion':
The paypernode_productapi does not appear to take as an argument anything useful for this, here's the decleration:
function paypernode_productapi(&$node, $op, $a3 = null, $a4 = null) {
But, I have to admit, I'm a bit fuzzy on how this whole module hooking into another module thing works, so I'm not really sure from where this function actually gets declared and called.