Miva Merchant 5 Module FAQs » Affiliate Manager 5.x (BROK_AFFILIATES5)


{docurl}

Is it possible to display data about the referring affliate on the Merchant pages and on the Invoice screen and notification emails?

Yes it is.  On each page in the store and during the processing of the order, the Affiliate Manager defines a number of global variables which can be accessed in the store and on the Invoice page and notification emails (for you developers out there, these varialbes are available at any point after the module's FulfillmentModule_ProcessOrder() function is processed).

The data can be accessed with a component token of the form:

&mvt:global:AffiliateData:code;

This token would display the referring affiliate's "code". It is arrived at by getting the variable below, g.AffiliateData:code, removing the g., adding:

&mft:global:

at the front, and ; at the end.

The global variables that are defined for the affiliate include:

g.AffiliateData:code
g.AffiliateData:id
g.AffiliateData:fname
g.AffiliateData:lname
g.AffiliateData:email
g.AffiliateData:company
g.AffiliateData:phone1
g.AffiliateData:phone2
g.AffiliateData:fax
g.AffiliateData:address
g.AffiliateData:city
g.AffiliateData:state
g.AffiliateData:country
g.AffiliateData:payout (the payout for this particular order)

An example application would be to display an affiliate specific log in the store.  If you name your logo graphics based on the affiliate's code (eg. alpha_logo.jpg, beta_logo.jpg, etc. for affiliates with code alpha, beta, etc.) you can "construct" the image path for the referring affiliate with:

<img src="&mvt:global:AffiliateData:code;_logo.jpg">


 



Last update: 2008-04-10 15:08
Author: Thor
Revision: 1.2

Print this record Send FAQ to a friend Show this as PDF file
Please rate this FAQ:

Average rating: 0 out of 5 (0 Votes )

completely useless 1 2 3 4 5 most valuable

You cannot comment on this entry