I'm using Zen Cart 1.3.8a, it is a basic install with no add ons, besides a new template.
I'm only offering a couple things, a service and a download file so I have nothing to ship, and integrated SonicFog's affiliate program.
The affiliate is pretty simple and uses cookies. I placed a line of code in my index.php page so when someone clicks the affiliate link and goes to my home page, it places a cookie on their computer with code that says, who, what and how much they earn. Now when a purchase is completed I need to add another line into the php on the final page that says the order was completed, that way the affiliate will earn their credit.
I'm using Paypal express. What php page should I add this other line into that shows the order was completed. Normally it would go into a thank you page.
I'm thinking it should be the ipn_main_handler.php because that is what I set at Paypal to return to once the sale is finished, and if it is this page, where on it should it go? The line I need to add is-
include_once "../affiliate/sale.php";
Thanks,
Dan
If anyone is curious about the affiliate code, and wants to use it, it wasn't complete and needed a lot of work to get going, and isn't usefull if you have a lot of products, because of the cookies, whatever affiliate product link the user clicked to get to your site is the only product the affiliate will get paid for, that is, if purchased. So if someone purchases additional items only the one item will be paid a commission on.



