CartHook
CartHook and Fairing integration.
Follow the below steps to set up Fairing post-purchase survey on your CartHook order confirmation page. CartHook recently launched a native Shopify integration that does not require this custom setup.
Step 1: Enable the CartHook integration
In your Integrations tab, select connect to access your survey script. To note, you'll need to be on the Fairing Pro plan to enable this integration.
Step 2: Copy your Fairing installation code
After you enable your CartHook integration, you'll be presented with your installation code. Copy this code as you'll need it for step 3.
Step 3: Paste Fairing installation code into CartHook Global Code
To access the Global Code page in your CartHook account, click the menu button on the top right and then "Global Scripts."
On the Global Code page, scroll down until you find the "Thank You page scripts" section and paste the Fairing installation code into the input box.
If you have multiple scripts in this section, you'll need to edit our script due to how CartHook processes their Global Scripts. Use the below script and copy and paste the enquirelabs.com URL from your script in line 3. More information in CartHook's docs here.
let script = document.createElement('script');
script.type = 'text/javascript';
script.src = 'PASTE URL FROM ENQUIRELABS SCRIPT HERE';
document.getElementsByTagName('head')[0].appendChild(script);
script.onload = function() {}
Step 4: Add survey script to thank-you page
If you're using CartHook's default confirmation page, this step may not be needed.
In your CartHook account, head to Funnels and click the funnel you're looking to add your Fairing post-purchase survey on. Next, click "Thank You Page" then "Edit Page."
On the following page, click </> to access the HTML of your confirmation page.
Insert the below code after line 8.
<div data-ch-type="text" data-post-purchase-survey></div>
Updated over 1 year ago