How to write google analytic code?

3 replies
How to write Google analytic code
#analytic #code #google #write
  • Profile picture of the author Chriswrighto
    Google gives you the code!

    Set up the account, follow the steps and you'll get one.
    Signature

    Wealthcopywriter.com :)

    {{ DiscussionBoard.errors[8945699].message }}
  • Profile picture of the author Shaf5280
    Here you go:

    <!-- Google Analytics -->
    <script>
    (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
    (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
    m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
    })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', 'UA-XXXX-Y', 'auto');
    ga('send', 'pageview');

    </script>
    <!-- End Google Analytics -->Sign up for a Google Analytics account and obtain a tracking code that you insert where is says "UA-XXXX-Y" in the above code.

    Here is a link the the help files: https://support.google.com/analytics..._topic=1726910

    If all else fails hire someone that knows what they are doing, I'm sure we have many on this forum.
    {{ DiscussionBoard.errors[8947420].message }}
  • after registering the analytic service you would be given a number of option to add code to your site.you may directly copy the code and embed on your index page.
    {{ DiscussionBoard.errors[8962520].message }}

Trending Topics