Forum
Welcome, Guest
Please Login to access forum.
Execute Facebook Pixel without page reload (1 viewing) 
Go to bottom
TOPIC: Execute Facebook Pixel without page reload
#8265
John Dagelmore
Admin
Posts: 3824
User Offline
Execute Facebook Pixel without page reload Karma: 84  
If you want to execute the Facebook Pixel without page reload, add the following script into a custom script section of the desired GDPR category, take care to replace your Facebook Pixel ID:

Code:

(function () { if (window.__fbPixelInjected) return; window.__fbPixelInjected = true; if (!window.fbq) { var f = function () { f.callMethod ? f.callMethod.apply(f, arguments) : f.queue.push(arguments); }; f.queue = []; f.version = '2.0'; window.fbq = f; window._fbq = f; } var t = document.createElement('script'); t.async = true; t.src = 'https://connect.' + 'facebook.' + 'net/en_US/fbevents.js'; t.onload = function () { fbq('init', 'XXXXXXXXXXXXXX'); fbq('track', 'PageView'); }; document.head.appendChild(t); })();
 
Logged Logged  
  The administrator has disabled public write access.
Go to top