Results 1 to 4 of 4

Thread: Google Analytics Code

Threaded View

  1. #1

    Google Analytics Code

    where to add the google Analytics Code

    The code should be placed in head.tpl NOT header.tpl
    tag <head> ....Google Code </head>
    I have added the code in file head.tpl (ftp://templates>>your_template>>tpl>>head.tpl)
    after the <head> tag
    Note: you have to add {literal} ... google code ... {/literal}

    <head>
    <!-- Global site tag (gtag.js) - Google Analytics -->
    {literal}
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-1660xxxxx-1"></script>
    <script>
    window.dataLayer = window.dataLayer || [];
    function gtag(){dataLayer.push(arguments);}
    gtag('js', new Date());

    gtag('config', 'UA-1660xxxxx-1');
    </script>
    {/literal}

    OK It's working fine
    Last edited by Amer Almusafer; February 28, 2021 at 08:48 PM.