Solved
Implementing Facebook Pixel
Dear all,
we are advertising a survey on Facebook and would therefore like to implement a Facebook Pixel in Qualtrics at a certain point.
The code provided by Facebook looks like this:
<!-- Facebook Pixel Code -->
<script>
!function(f,b,e,v,n,t,s)
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];
s.parentNode.insertBefore(t,s)}(window, document,'script',
'https://connect.facebook.net/en_US/fbevents.js');
fbq('init', 'ID');
fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none"
src="https://www.facebook.com/tr?id=ID&ev=PageView&noscript=1"
/></noscript>
<!-- End Facebook Pixel Code -->
If we try to add it via "Add Javascript" we always get the following error message:
Best answer by mattyb513
If I were you I would take the initial function and drop it in the header between html script tags like so:
```
<script>
!function ....
all the way until
fbq('init', 'ID');
</script>
```
I would then put the pageView tracker or any other custom conversions you want in the Add Javascript section, like so
```
/* Add JavaScript Below This Line */
fbq('track', 'PageView');
```
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.

Thanks,