PDA

View Full Version : Webgains Integration in Seven


Orchid
13-Aug-2007, 09:11 AM
I'm doing an integration for webgains - it needs to produce the following output.



<noscript><img src="h**p://track.webgains.com/transaction.html?wgver=1.1&wgprogramid=772&wgrs=1&wgvalue=55.67&wgeventid=1334&wgorderreference=NETQUOTEVAR:THEORDERNUMBER" />
</noscript>


NETQUOTEVAR:ACTINICORDERTOTAL - is the closest to this format but produces 5567 so I will need to divide it by 100. Because this is in a noscript tag I can't do this client side but will instead need to do it in the perl script by copying ACTINICORDERTOTAL into a new variable dividing by one hundred and then outputing it.

Therefore does anyone know which:

Which perl script do I need to alter
Any idea which line (part of code) deals with the outputting of ACTINICORDERTOTAL?

Orchid
14-Aug-2007, 07:39 AM
I should have searched forum for 'ACTINICORDERTOTAL' before posting, for anyone interested the solution is pasted below.

In orderscript.pl the relevant part now reads


# send the total as an integer in the currency base unit
# e.g. "512834"
#
$::s_VariableTable{$::VARPREFIX.'ACTINICORDERTOTAL'} = $nTotal;
#
# send the total as an integer in the currency base unit
# e.g. "5128.34" as inserted by MDJ for affiliate tracking
#
$::s_VariableTable{$::VARPREFIX.'ACTINICORDERTOTAL100'} = $nTotal/100;
#
# send the total as a formatted string
# e.g. "$5,128.34"


You can then use the NETQUOTEVAR:ACTINICORDERTOTAL100 in Act_Order04
__________________
Mike Julien

www.wheesh.com (http://www.wheesh.com)