Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2011
    Location
    Adelaide, Australia
    Posts
    1,670
    Plugin Contributions
    1

    Default adding Facebbok Pixel to head of ... which page?

    need some help here please - where in a ZC store does one place a script like this for it to work - instructions say between <head> and </head> (Facebook Pixel Code - tracks analytics from Facebook Ads to a website)

    I tried just uploading it as a notepad file in the root but that hasn't worked (doh) - so where do I put it?

    <!-- 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','//connect.facebook.net/en_US/fbevents.js');

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

    cheers, Mike

  2. #2
    Join Date
    Sep 2008
    Location
    WA
    Posts
    555
    Plugin Contributions
    0

    Default Re: adding Facebbok Pixel to head of ... which page?

    Hi Mike
    /includes/templates/your-template/common/html_header.php is where all of the stuff before /head is loaded. You could put it in there, but I am not sure if that is the "proper" way to do it.

    If you look at the file it goes through all of the places that it loads scripts from. I would guess that you would create your script file put it into /includes/templates/yourtemplate/jscript.

  3. #3
    Join Date
    Jan 2011
    Location
    Adelaide, Australia
    Posts
    1,670
    Plugin Contributions
    1

    Default Re: adding Facebbok Pixel to head of ... which page?

    Quote Originally Posted by lruskauff View Post
    Hi Mike
    /includes/templates/your-template/common/html_header.php is where all of the stuff before /head is loaded. You could put it in there, but I am not sure if that is the "proper" way to do it.

    If you look at the file it goes through all of the places that it loads scripts from. I would guess that you would create your script file put it into /includes/templates/yourtemplate/jscript.
    many thanks for your response,
    cheers, Mike

 

 

Similar Threads

  1. non-english head tags goes out of <head></head>
    By Jerry5763837 in forum General Questions
    Replies: 5
    Last Post: 5 Jun 2012, 02:21 PM
  2. HELP! Main page <head></head>
    By mwnname in forum Basic Configuration
    Replies: 2
    Last Post: 21 Nov 2009, 02:23 PM
  3. Adding code to <head> tags in ezpages
    By donplay in forum General Questions
    Replies: 1
    Last Post: 3 May 2009, 05:13 AM
  4. Adding a head tag script
    By gardengate in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 13 Oct 2006, 01:46 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR