- 24 May 2022
- 1 Minute to read
- Print
- DarkLight
Dynamic Values For Tracking Code
- Updated on 24 May 2022
- 1 Minute to read
- Print
- DarkLight
Are you using Facebook Pixels, Google Analytics or another tracking software to track and measure conversions on LightSpeedVT checkout pages? If so, then we have a treat for you.
LSVT makes it easy for you to use these tracking tools with accuracy by allowing you to pass dynamic values to your tracking tools, here are some of the values that can be used.
Key | Value |
---|---|
{subscriptionId} | Chargify subscription id |
{productName} | Chargify product name |
{productHandle} | Chargify product handle |
{productId} | Chargify product id |
{productPrice} | Chargify product price point |
{transactionId} | Transaction id |
{tax} | Tax amount |
{totalAmount} | Total amount of product not including discounts |
{adjustedAmount} | Amount charged after discounts |
{title} | Title of the checkout page |
{subscriptionType} | Individual purchase or Location purchase |
{system} | System name |
{coupon} | Coupon code used |
{currency} | Currency |
Let’s say you wanted to pass the amount charged after any coupon discounts were applied, the currency type, and the chargify product handle. You can use the {adjustedAmount}, {currency} and {productHandle} dynamic values to pass that information to your tracking software, here’s an example.
fbq(‘track’, ‘Purchase’, {
value: {adjustedAmount},
currency: {currency},
coupon: ”,
contents: [{
id: ‘{productHandle}’,
quantity: 1
}],
content_type: ‘product’
});
By using these dynamic fields you’re able to get accurate information no matter what changes are made to the product over time. To drop tacking code into the checkout page, navigate to the Super User Dashboard then click on Integration Management [105] located under the “Account” column.
Choose the “Chargify Individual Purchase” from the “Chargify Integration” drop down.
Next, choose the checkout page that you wish to add the code to by clicking on the name of the checkout page.
Once in the checkout page, click on the “Form Settings” tab and scroll down to the section labeled “Custom Code, CSS, JS”. This section gives you the ability to drop code in the head, body, and footer of the start page and thank you page.