TABLE OF CONTENTS
First you have to inject our integration script into your website.
<aside> <img src="/icons/exclamation-mark_green.svg" alt="/icons/exclamation-mark_green.svg" width="40px" /> The Prefixbox integration script should be added to the <head> section of the website, and it should be part of all pages (including product pages).
</aside>
The script is the following:
<!-- Prefixbox Integration -->
<link rel="preconnect" href="<https://integration.prefixbox.com/>" />
<link rel="dns-prefetch" href="<https://integration.prefixbox.com/>" />
<link rel="preconnect" href="<https://api.prefixbox.com/>" />
<link rel="dns-prefetch" href="<https://api.prefixbox.com/>" />
<script>
window.prefixboxAnalytics=window.prefixboxAnalytics||function(t,s,p,o){(window.pfbxQueue=window.pfbxQueue||[]).push({type:t,source:s,params:p,overrideObject:o});};
window.prefixboxFunctions=window.prefixboxFunctions||{}; window.prefixboxCustomerFunctions=window.prefixboxCustomerFunctions||{};
</script>
<script
id="prefixbox-integration-v2"
async
defer
fetchpriority="high"
type="text/javascript"
src="<https://integration.prefixbox.com/{websiteTracker}>"
/>
<!-- End Prefixbox Integration -->
or alternatively you can use Google Tag Manager (note: performance will be worse) :
<!-- Prefixbox Integration -->
<script>
window.prefixboxAnalytics=window.prefixboxAnalytics||function(t,s,p,o){(window.pfbxQueue=window.pfbxQueue||[]).push({type:t,source:s,params:p,overrideObject:o});};
window.prefixboxFunctions=window.prefixboxFunctions||{}; window.prefixboxCustomerFunctions=window.prefixboxCustomerFunctions||{};
const ps = document.createElement('script');
ps.id = "prefixbox-integration-v2"
ps.async = true;
ps.defer = true;
ps.fetchPriority = "high";
ps.type = "text/javascript";
ps.src = "<https://integration.prefixbox.com/{websiteTracker}>";
document.getElementsByTagName("head")[0].appendChild(ps);
</script>
<!-- End Prefixbox Integration -->