Hello folx,
I just tried to integrate an affilate programm (AMIGOS - affiliate tracking).
I guess the best way would be to add an Event for the Tracking at
com_netinvoice/events/payment_received/payment_received.amigos.php
if (!empty($_REQUEST['amigosid'])) {
//Initialise
$amigos_params['amigos_id'] = $_REQUEST['amigosid'];
$amigos_params['amigos_ordertype'] = 'xxx';
$amigos_params['amigos_orderid'] = $params["order_ids"];
$amigos_params['amigos_orderamount'] = format_number($params["amount"], 2);
$amigos_params['task'] = 'sale';
$amigos_params['option'] = 'com_amigos';
$amigos_host = 'http://myhost';
$amigos_page = 'index2.php';
nbGetHTTP($amigos_host,$amigos_page,$amigos_params);
But the Problem is the IPN/Callback gets called from the payment provider e.g. Paypal ... so they dont have the ID COOKIE.
So I thought why not simple add &amigosid=$_COOKIE['amigosid'] to the IPN/Callback URL so the callback should have the
correct Value for the ID field so I could count the affiliate Lead.
Is there a "simple" way to do so?? or there to start.
thx a lot
Thomas