how add google analytics without <script>

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Emad ELsayed
    Senior Member
    • Jan 2013
    • 151
    • 4.2.x

    how add google analytics without <script>

    welcome
    How to add Google analytics to the forum without the opening and closing <script>

    This is the Java code for Google
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-149478561-1"></script>
    <script>
    window.dataLayer = window.dataLayer || [];
    function gtag(){dataLayer.push(arguments);}
    gtag('js', new Date());

    gtag('config', 'UA-149478561-1');
  • Wayne Luke
    vBulletin Technical Support Lead
    • Aug 2000
    • 74172

    #2
    You should be able to use that code as is in vBulletin 5.4.0 and higher.

    Last edited by Wayne Luke; Wed 14 Mar '18, 10:08am.
    Translations provided by Google.

    Wayne Luke
    The Rabid Badger - a vBulletin Cloud demonstration site.
    vBulletin 5 API

    Comment

    • Emad ELsayed
      Senior Member
      • Jan 2013
      • 151
      • 4.2.x

      #3
      Originally posted by Wayne Luke
      You should be able to use that code as is in vBulletin 5.4.0 and higher.
      Does it mean that it should not be deleted opening and closing <script>

      *** Click image for larger version

Name:	Untitled.png
Views:	53
Size:	17.1 KB
ID:	4387965

      Comment

      • Wayne Luke
        vBulletin Technical Support Lead
        • Aug 2000
        • 74172

        #4
        The description is wrong.
        Translations provided by Google.

        Wayne Luke
        The Rabid Badger - a vBulletin Cloud demonstration site.
        vBulletin 5 API

        Comment

        • Emad ELsayed
          Senior Member
          • Jan 2013
          • 151
          • 4.2.x

          #5
          Originally posted by Wayne Luke
          The description is wrong.
          Thank you dear

          Comment

          Related Topics

          Collapse

          Working...