AKMG: Variable Scope And The Affiliate Tracking System
Sunday, September 13th, 2009
You’re an affiliate marketer or an affiliate network operator. You deal with massive amounts of data and data relationships every single day. You often find yourself not only having to receive certain data but having to send back data to your partners, post conversion.
The passing back of data to your partners or clients might seem pretty rudimentary, but you’d be very surprised to find out that many tracking systems lack a comprehensive version of this functionality because of variable scope issues.
Variable scope is basically a set of rules that defines where one can and can not access a variable. About.com explains it best here, “you can’t define a variable at any spot in the program and use it at any spot, there is a specific relationship between where a variable is defined and where it can be used.” What this means for your tracking platform is that any data that is required to be ’sent back’ to your partner/client through a pixel or any other means must be within the ’scope’ of that end-pass or end-population.
Example:
- A publisher sends a value to you through your tracking URL and needs it passed back to their pixel.
- If this value, passed into a parameter in the initial URL, is definable and in the scope of the pixel, you can pass it back without a problem.
I won’t go into specific implementations here, because the definition and handling of local and global variable scopes varies from framework to framework. The logic, per the above, however, will never change.
If your current system doesn’t allow much flexibility for data handling, you may want to consider switching software!










