Link to home
Start Free TrialLog in
Avatar of Porffor
PorfforFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Getting Facebook Pixel to track completed registrations rather than page hits

Hello, I've read many conflicting reports about this, so I thought I'd throw it to the experts...

An organisation has a website that has a website where people can join the organisation, by filling in a form and set up a payment through paypal. There are separate pages for monthly, annually and concessions membership. And in two languages, so 6 pages in total.

This is an example of one of those web pages... https://www.yes.cymru/joinmonthly

The organisation wants to set up Facebook Pixel to track how effective its Facebook posts are at getting people to join. The membership process is all contained in one page, so there is no 'Thank you page' that people land on for us to put the Pixel code in there. I could set this up, but I'd need 6 of these pages in order to track all the different types of membership, therefore this would be a bit messy.

I've heard that Pixel can be adapted so that it tracks form submits rather than page hits. I've heard others saying that you need Google Tag Manager to do this.

Here's the code that was generated fro Pixel, which I've put into my webpages...

<!-- 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', '############');
  fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none"
  src="https://www.facebook.com/tr?id=############&ev=PageView&noscript=1"
/></noscript>
<!-- End Facebook Pixel Code -->

Open in new window


Now, I might be reading too much into the above, but when I see the line "fbq('track', 'PageView');", it makes me think that this isn't what I need. Especially when I read the following article which mentions a 'CompleteRegistration' event instead... https://developers.facebook.com/docs/facebook-pixel/reference#events

Do I therefore need to swap the 'PageView' bit on lines 12 and 15 of the code to 'CompleteRegistration' instead, or another one? Or is this not the solution?

Thanks.
SOLUTION
Avatar of Lucas Bishop
Lucas Bishop
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Porffor

ASKER

Hi Lucas, thanks for your post.

I can see now that moving the Pixel code from the individual pages to the theme file would be beneficial here, so get pageview data on every page.

I've had a look at the Conversion Tracking article before. It gives code examples, but it doesn't show how to use the code in the context of the rest of the Pixel code, therefore I still have many unanswered questions.

But yeah, but as for the specific use that I have with membership, recording page loads would be insufficient in terms of reporting, because a new membership depends of the user having filled in all the fields. In the same manner, tracking button clicks isn't 100% either, because someone might fill only half the form and then click submit, only to find that the site doesn't let them continue until they've filled in the remaining boxes. Some people might give up at this stage, because they don't want to give their postal address for example. Or, does the button click only trigger an event if the button has been clicked 'successfully'?

I will certainly check out Google Tag Manager. I can install the code for that no problem.

By the way, that screenshot you sent - is that Pixel or GTM? I still don't quite understand the relationship between Pixel and GTM. If Pixel is recording only pageviews, then how is GTM able to record completed registrations and pass the data to Pixel?

Thanks.
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Porffor

ASKER

Great, thanks for your help.