When the purchase transactions are complete, run the code below.
Submit the product codes in the OM.pp
parameter, separating them with a semicolon.
Submit the quantity of the relevant product in the basket in the OM.pu
parameter, separating them with a semicolon.
In the OM.ppr
parameter, multiply the price of the relevant product and the number in the basket and send them by separating them with a semicolon.
The OM.tid
order number must be different for each order.
Note |
---|
The |
Code Block |
---|
var data = {
"OM.tid" : transactionID,
"OM.pp" : "Product1 Code;Product2 Code",
"OM.pu" : "Product1 Quantity;Product2 Quantity",
"OM.ppr" : "Product1 Price*Product1 Quantity;Product2 Price*Product2 Quantity",
"OM.exVisitorID" : keyID
};
visilabsApi.customEvent("Purchase", data); |
Info |
---|
You can review the sample usage in line 30. on this page. |
Info |
---|
You can review the sample usage in line 26. on this page. |
Ui button | ||||||
---|---|---|---|---|---|---|
|