Skip to main content
All CollectionsFeatures
Tracking Scripts
Tracking Scripts
Giancarlo Massaro avatar
Written by Giancarlo Massaro
Updated over 7 months ago

This feature is only available on our Business Plan and higher.

Note: Due to browsers like Safari and Firefox blocking 3rd party cookies and tracking by default, this method may not always work as intended. If you are using the URL ViralSeep provides to run your promotion, you can use this feature. If you are embedding ViralSweep into your own website, we suggest adding tracking scripts to the page on your website outside of our form. Click here to see explanation below on how to accomplish this.

The Tracking Scripts feature allows you to add 3rd party tracking and conversion scripts onto the pre-entry and post-entry pages of the campaign. This will allow you to track pageviews, clicks, or conversions from all of your marketing campaigns.

To use this feature, simply paste your tracking scripts into either the pre-entry or post-entry tracking pixels box. To add multiple scripts, separate each one so it appears on a new line.

If you are pasting a script into the pre-entry box, this script will fire on when the user lands on your campaign and the ViralSweep form successfully loads.

If you are pasting a script into the post-entry box, this script will fire upon successful completion of the entry form. So if a user lands on your campaign and does not enter, the script will not fire.

Pass data into your script

If you want to pass an email into the script after the user has submitted the ViralSweep form, simply populate your script with the below parameters:

[EMAIL]

[FIRST_NAME]

[LAST_NAME]

[ADDRESS]

[CITY]

[STATE

[ZIP]

[COUNTRY]

[PHONE]

To pass custom fields, you will need to add the fields to your entry form first, then visit your entry form, and using the browser inspect tool, select the field and find its ID. For example if your field is called "colors" with a field ID of 83520_1653480537, then to pass it you would use:

[83520_1653480537]

If you need assistance with this, please contact us.

Example Use Case

If you are running Google Adwords to your campaign, you would want to create an Adwords conversion tag to add to your campaign so that you know how many pageviews and conversions you are getting.

You would simply obtain the conversion tag from your Adwords dashboard and paste it into the tracking scripts section within ViralSweep

Inside of your Google Adwords dashboard, you will now be able to track the number of pageviews and conversions coming from your Google ads.

Add scripts to your own website

Many browsers now block 3rd party scripts that are embedded within an iframe. Soon, all browsers will block these. If you are embedding ViralSweep into your own website, then you will need to add your tracking scripts into your website, instead of within ViralSweep. Here is how you can accomplish this:

1) Create two pages on your website, one is your entry page, and the second is your thank you page. We'll call these Page A and Page B. Embed the ViralSweep code snippet into both pages.
โ€‹
2) In ViralSweep, under edit > advanced > redirect upon entry > input the URL to the thank you page, otherwise known as Page B. Makes sure to toggle redirect upon entry to YES.

3) Embed you tracking scripts on your pages directly, NOT inside of ViralSweep on our tracking scripts feature. So if you have a script to track pageviews, put that on Page A. If you have a script to track conversions, put that on Page B.
โ€‹
4) Now when someone lands on page A your script will fire. When they submit our form, we automatically redirect them to Page B, and any scripts you added to that page will also fire. In addition, as long as you have ViralSweep installed on that page, the user will see our post-entry screen.

We're here to help

If you have any further questions, please start a Chat. Just "Click" on the chat icon in the lower right corner to talk with our support team.

Did this answer your question?