Bienvenue sur le Service Client de Kelkoo

Exemples de codes Tradedoubler

Vous trouverez ci-dessous les exemples de codes Tradedoubler les plus pertinents dans différents langages de programmation. Il s’agit juste d’exemples, vous ne pouvez pas les utiliser directement sans les personnaliser.


PHP

<?
//Change to organization id provided by TradeDoubler/Kelkoo
$org_id = 222404;
//OrderValue = total including shipping and taxes.
//Cannot consist of, (comma) or spaces. Decimal sign is . (dot)
// Important no thousand separators.
$orderValue = "102.50";
//Change to the unique order number.
$orderNumber = "111";
//event supplied by TradeDoubler/Kelkoo.
$event = 1211;
//currency = 3-letter code for currency of ordervalue.
//Correct currency vlue can be forun in the table 'Country, currency and language identification'
$currency = "GBP";
echo "<img src=""http://tbs.tradedoubler.com/report?organization=".$org_id."&event=".$event."&orderNumber=".$orderNumber."&orderValue=".$orderValue."&currency=".$currency.""" alt="" />";
?>

JSP

<%
//Change to organization id provided by TradeDoubler/Kelkoo
String organization = "11";

//Cannot consist of , (comma) or spaces. Decimal sign is . (dot)
String orderValue = "102.50";

//Change to the unique order number or lead number
String orderNumber = "111";

//event supplied by TradeDoubler/kelkoo
String event = "1000";

//currency = 3-letter code for currency of ordervalue.
//Correct currency vlue can be forun in the table 'Country, currency and language identification'
String currency = "GBP";
%>

<img src="http://tbs.tradedoubler.com/report?organization=<%=organization%>&event=<%=event%>&orderNumber=<%=orderNumber%>&orderValue=<%=orderValue%>&currency=<%=currency%>" alt="" />

<%
//To test if TradeDoubler works, choose "Show Source" when you display the
//invisible tracking image. Put the url in the browsers address field and add &debug=2
//and see if the checksum is CORRECT.
%>

PERL

---------------------------------------
#!/usr/bin/perl
use CGI;
use CGI::Carp qw(fatalsToBrowser);
my $cgi = new CGI;

#/Change to the unique order number.
$ordernumber = "111";

#ordervalue = total including shipping and taxes.
#Cannot consist of , (comma) or spaces. Important no thousand separators.
#Decimal sign is . (dot).
$ordervalue = "1102.50";

#organization = id number, provided by TradeDoubler/kelkoo
$organization = 222404;
#Supplied by TradeDoubler/kelkoo
$event = 1212;

#currency = 3-letter code for currency of ordervalue.
#/Correct currency vlue can be forun in the table 'Country, currency and language identification'
$currency = "GBP";

#=======================================================================================#
#/////////////////////////////////////////////////////////////////////

print "<img src=""http://tbs.tradedoubler.com/report?organization=$organization&event=$event&orderNumber=$ordernumber&orderValue=$ordervalue&currency=$currency"" alt="" />";
print CGI->end_html();

ASP (Classic)

<% dim ordernumber, ordervalue, organization dim curr, eventid 'This part should be implemented after you have retrieved all variables and displayed 'the receipt. ordernumber = "111" 'ordervalue = total including shipping and taxes. Cannot consist of, (comma) or spaces. 'Decimal sign is . (dot). Important no thousand separators. ordervalue = "102.50" 'organization = id number, provided by TradeDoublerKkelkoo organization = 50 'Supplied by TradeDoubler/kelkoo eventid = 1000 'currency = 3-letter code for currency of ordervalue. 'Correct currency vlue can be forun in the table "Country, currency and language identification' curr = "GBP" %>
<img src="http://tbs.tradedoubler.com/report?organization=<%=organization%>&event=<%=eventid%>&orderNumber=<%=ordernumber%>&orderValue=<%=ordervalue%>&currency=<%=curr%>" alt="" />

ASP.Net C #

<%@ Page language="c#" %>
<% //Change to the unique order number or lead number int orderNumber = 123456; //Cannot consist of , (comma) or spaces. Decimal sign is . (dot) int orderValue = 1; //Change to organization id provided by TradeDoubler/Kelkoo int organization = 51; //event supplied by TradeDoubler/kelkoo int eventId = 5; //currency = 3-letter code for currency of ordervalue. //Correct currency vslue can be found in the table 'Country, currency and language identification' string currency = "GBP"; %>
<img src="http://tbs.tradedoubler.com/report?organization=<%=organization%>&event=<%=eventId%>&orderNumber=<%=orderNumber%>&orderValue=<%=orderValue%>&currency=<%=currency%>" alt="" />

ASP.Net VB

<%@ Page Language="vb"%>
<% Dim orderNumber As String = "123456" ' Cannot consist of , (comma) or spaces. Decimal sign is . (dot) Dim orderValue As String = "1" ' Change to organization id provided by TradeDoubler/Kelkoo Dim organization As String = "51" ' currency = 3-letter code for currency of ordervalue. ' Correct currency vlue can be forun in the table 'Country, currency and language identification' Dim currency As String = "GBP" ' event supplied by TradeDoubler/kelkoo Dim eventId As String = "5" %>

<img src=""http://tbs.tradedoubler.com/report?organization=<%=organization%" alt="" />&event=<%=eventId%>&
orderNumber=<%=orderNumber%>&orderValue=<%=orderValue%>&currency=<%=currency%>"/>