Welcome to TalkGraphics.com
Results 1 to 9 of 9
  1. #1
    Join Date
    Jul 2015
    Location
    Pennsylvania, USA
    Posts
    30

    Default Placement of Google analytics code - Problem???

    Hi again,

    I'm using Web Designer 11 premium, and went to the menu box that it has for google analytics. Then went to google's site to get the code that Xara says to copy/paste into the menu box.

    Google's site says to paste their code "so that it appears immediately after the opening <body> tag". So, I thought I would double check where Xara puts it.

    Couldn't find an option to see the HTML directly, so I exported as HTML to my desktop and opened the file with Windows notepad.

    Xara puts it instead right before the final </head> tag. I even tried using the Web Properties menu - HTML (body) - to insert the code, but that inserts in right before the final </body> tag.

    Nothing is putting it where google says it is supposed to go. Do I have to do it manually. My web host has a file manager where I can open a page's HTML in a text editor and put it in myself. I would have to do each page individually.

    Does it matter? I would think that google wouldn't tell you that if it didn't matter.

    ?????????????

    Thanks, Mark.

  2. #2
    Join Date
    Jan 2001
    Location
    East Sussex, England
    Posts
    2,021

    Default Re: Placement of Google analytics code - Problem???

    I've never had any problem with where Xara puts it.
    Christine

    Software: XDPX9, WD9,WD10,XDPX10,WD11,XDPX11,XDP365

  3. #3
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,532

    Default Re: Placement of Google analytics code - Problem???

    There is a tab in Web Properties, Analytics

    Paste your code in here.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	analytics.png 
Views:	145 
Size:	16.9 KB 
ID:	109270  

  4. #4
    Join Date
    Jul 2015
    Location
    Pennsylvania, USA
    Posts
    30

    Default Re: Placement of Google analytics code - Problem???

    On further research, what I found is that for basic Google Analytics, xara does put the tag code snippet where it should go (immediately before the closing </head> tag).

    However, for Google Tag Manager, xara does not put it where it should go (immediately after the opening <body> tag).

    At least, that's where Google itself is saying where they want the code to go.

    Therefore, I will have to put in the code manually from my webhost after I publish.

  5. #5
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,532

    Default Re: Placement of Google analytics code - Problem???

    Try it first using the dialog I showed you. I have Google Analytics on all of my websites and I have never had any issues. You might be overthinking this.

    Because of the way Web Designer is set up, you will need to modify the code every time you publish and if there is no need to do this then why bother?

  6. #6
    Join Date
    Apr 2015
    Posts
    22

    Default Re: Placement of Google analytics code - Problem???

    I copied and pasted the <script> code chunk from Google Analytics into the proper Analytics box on web properties and when I look at the page source, it is correctly placed (not using Tag manager). However, Google swears up and down that the Google Analytics code is not recognized. What am I doing wrong? It seems to be set up properly on Google and it appears correct in Xara Designer Pro 11.

    Code:
    Status: Tracking Not Installed
    Last checked: Oct 5, 2015 8:05:14 PM PDT
    The Google Analytics tracking code has not been detected on your website's home page. For Analytics to function, you or your web administrator must add the code to each page of your website.
    Learn more
    Thank you for the help.

    Mike

  7. #7
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,532

    Default Re: Placement of Google analytics code - Problem???

    Are you pasting your code here (see attached). And does the code you are placing have your site address and your Google account info?
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	code here.png 
Views:	107 
Size:	16.5 KB 
ID:	110438  

  8. #8
    Join Date
    Apr 2015
    Posts
    22

    Default Re: Placement of Google analytics code - Problem???

    Yes, that is exactly where I copied and pasted the code directly from Google. The instructions were clear - copy and paste exactly as provided. I did that. It has the account info embedded in the code.

    I spoke too soon. It is now tracking data. It must take 24 hours to start working.

    Thank you for trying to help.

    Mike

  9. #9
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,532

    Default Re: Placement of Google analytics code - Problem???


 

 

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
  •