...
...
...
...
Overview
Instructions to send "Wishlist" clicks information using the Javascript Tagging Library.
Step-by-step guide
This event must be triggered when users click on "Wishlist" button. At that moment trackWishlist function should be executed including parameters detailed below.
trackWishlist
Use this function to send information when a user clicks on an "Wishlist" button.
Code Block | ||
---|---|---|
| ||
trackWishlist(terms, page, position, productid, title, url, options, callback) |
Parameters
Parameter | Description | Data Type | Mandatory |
---|---|---|---|
terms | The query typed by the user | String | Yes |
page | The page number | Integer | Yes |
position | The position in SERP of the product selected. | Integer | No |
productId | The product ID of the selected result. | String | No |
title | The product or result title | String | Yes |
url | Destination URL, for example product detail page | String | Yes |
options | Object that may contain information about filters and other required data | Object | No* |
callback | Function that will be executed after sending data | Function | No |
*This parameters are not mandatory for the service but necessary for the statistics |
Options
The options object should contains additional parameters not passed as parameters in function call:
...
Code Block | ||
---|---|---|
| ||
{ q: terms, page: page, productId: productid, position: position, title: title, url: url, follow: false } |
Code sample
Code Block | ||
---|---|---|
| ||
empathyTAG.trackWishlist('test', 1, 3, "My product id", 'My product title', 'http://MY_PRODUCT_URL.com',{lang:'en',scope:'testscope'},function(){}); |
Related articles
Filter by label (Content by label) | ||
---|---|---|
|