Welcome to WebmasterWorld Guest from

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

affiliate software creation. how to get vars from advertiser

9:36 am on Nov 29, 2013 (gmt 0)

Junior Member

10+ Year Member

joined:Aug 7, 2008
posts: 93
votes: 0

I am creating a basic and small program in php like cj and linkshare. its not that big and complicated.

But I need to know about the logic how it actually gets to know if the sale is completed or not on advertiser's website once the affiliate's url is clicked?

Appreciate the suggestions and advices.

3:06 pm on Nov 29, 2013 (gmt 0)

Senior Member from ES 

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:July 24, 2002
votes: 2


you need to insert a bit of code on the confirmation page, e.g.
<img src="https://www.example.com/affiliate_sale_tracker.php?var1=&var2=&var3=">
where var1, 2 and 3 contain for example the order number, the total amount and any other var you wish to record.

you'll also need to have some sort of check to ensure that each order number is only credited once to each affiliate.

i've done this myself and use the software on our own site. however... it is difficult and you also need a backend for affiliates to check sales and it must be rock solid and secure - otherwise you'll never get affiliates to trust you.

all big companies use js script tag instead of php in img src, because js is platform independent. on my own server i am able to use php, so i used the method above.

good luck
3:32 pm on Nov 29, 2013 (gmt 0)

Junior Member

10+ Year Member

joined:Aug 7, 2008
posts: 93
votes: 0

Thanks for your reply.

To understand better, example.com will be the domain where my affiliate program is running?

Also the var1,2 and 3 etc. how do I get the values from advertisers' site? Do I have to ask them to pass those variables from their site?

Thanks again for your help.