If you're using a third-party conversion or sales tracking system to report on your store's sales activity, you may be required to insert some custom web scripts into a portion of your store. Fortunately, there's a placeholder in your store's Admin Area designed specifically for this purpose!

Editing Article 130

To add third-party conversion tracking code, such as Facebook pixel or Google Analytics tracking scripts, edit article ID # 130 as follows:

  1. From your Admin Area, go to Design > Site Content.

  2. Scroll down until you find Article ID # 130. If this article doesn't exist in your store, or if it exists but does not have the Spot Key set to ROI_Javascripts, click View List at the top of the page and use Search to find an article with ROI_Javascripts in the Spot Key field.

  3. Click the article ID number.

  4. In the Article Body field, click the HTML icon in the Easy Editor toolbar.

  5. Enter or paste the following script into the Article Body field and click Save.

Once the tracking script has been saved in the article body, it will populate throughout your store and you'll be able to use any relevant conversion analytics.

By default, this article will be empty. However, if you need to allocate space in this article body for additional HTML, text, or other web scripts, you may do so. This article is specifically designed for use with ROI tracking scripts, but is not exclusive for their use.

The Google Analytics tracking script will look similar to the example below:

<script type="text/javascript">
  try {
    let items = []
    for (var i=0; i < OrderDetails.length; i++)
          "id": OrderDetails[i][2],
          "name": OrderDetails[i][3],
          "quantity": OrderDetails[i][6],
          "price": OrderDetails[i][5]
    gtag('event', 'purchase', {
      "transaction_id": Order[0],
      "affiliation": 'Volusion Shopping Cart',
      "value": Order[2],
      "tax": Order[4],
      "shipping": Order[5],
      "items": items
  catch(e) {}
<!-- END -->

Please note that in order for the Google Analytics Conversion Tracking script to function, you'll also need to enable Ecommerce within your Google Analytics account. To do so, log in to Google Analytics and navigate to your domain's Admin > View > Ecommerce Tracking section. Make sure the Ecommerce Tracking status is set to On.

For more information regarding Google Analytics integration with your store, please see Setting Up Google Analytics.

Conversion Tracking vs. Analytics

Note that the steps outlined above refer to the use of third-party ROI tracking scripts to measure your store's conversion data - the rate at which unique visits to your store are converted into sales. When using more robust web analytic systems such as Google Analytics that track data globally throughout your website, you'll need to follow a different set of instructions to integrate these analytics scripts with your store.

Generating Your Own Tracking Scripts

In most cases, your ROI tracking service will provide some form of scripts (generally JavaScript) for you to include in your site. However, there are some advanced functions that will allow you to create your own custom JavaScript for the purpose of customized ROI tracking integration.

The following notes on creating tracking scripts are intended for advanced users familiar with ROI tracking systems and JavaScript programming.

Please note that Volusion supports HTML, CSS, JavaScript, and ASP web code (where available). PHP and other scripting languages are not supported.

Where Order-Specific Information is Generated

Order-specific information can be generated by JavaScript on the OrderFinished.asp page within Volusion. Two JavaScript arrays will be initialized that you may need to be aware of:

Order Array Contents

  • Order[0] = Order ID

  • Order[1] = Unused

  • Order[2] = Payment Amount

  • Order[3] = Affiliate Commissionable Value

  • Order[4] = Sales Tax

  • Order[5] = Total Shipping Cost

  • Order[6] = Billing City

  • Order[7] = Billing State

  • Order[8] = Billing Country

  • Order[9] = Email Address

OrderDetails Array Contents

  • OrderDetails[X][0] = Order ID

  • OrderDetails[X][1] = Order Detail ID

  • OrderDetails[X][2] = Product Code

  • OrderDetails[X][3] = Product Name

  • OrderDetails[X][5] = Product Price

  • OrderDetails[X][6] = Quantity

Note that in the above example, [X] refers to an OrderDetail line item number (beginning from zero). There may be multiple OrderDetails arrays - one for each unique item contained within an order.

If you need to install a custom or third-party web script into your store, see "How to Install a Third-Party JavaScript".

Facebook Pixel

To install Facebook Pixel code:

  1. Go to Design > File Editor.

  2. On the right, under the Shortcuts heading, below the Theme Files subheading, select Template_ABC.html (where "ABC" is a placeholder for your theme's name or ID number).

  3. Locate the </head> tag in the editor window (you can use your browser's find function to locate it quickly).

  4. Enter a customized version of the code below above this tag. Note that we always strongly recommend archiving your theme before editing it. This will allow you to restore it easily if you make an error and damage your store functionality.

<!-- Facebook Pixel Code -->
 fbevents.js'); fbq('init', '1234567890');
 fbq('track', 'PageView');
 <img height="1" width="1" style="display:none"
<!-- End Facebook Pixel Code -->

For more information on Facebook pixel, see Facebook's documentation.

See Facebook's list of all possible events you can track with the Pixel. Note that some events may not work as intended on the Volusion platform.

Did this answer your question?