/tagmanager/community?hl=en
/tagmanager/community?hl=en
11/19/13
Original Poster
Google user

Google Tag manager to blogger?

Hi,
I am trying to add the Google Tag manager to my blog and I keep getting this:
Error parsing XML, line 10, column 43: The reference to entity "l" must end with the ';' delimiter.
 
Can you help me figure out what I am doing wrong? Thank you.
Community content may not be verified or up-to-date. Learn more.
All Replies (49)
claudia_k
11/20/13
claudia_k
Hi there,

This is a problem with blogger and GTM - blogger parses everything as XML which causes problems with the GTM tag.
Try the following:
In the code of your container tag you should see this line
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=

replace that line with this line - the change is highlighted in bold
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=

Then copy the adjusted code in your blogger template and save the template - it should work now. When you then check the source code of the website you can see that the '&' has been changed back by blogger to the correct '&', so the code that is actually included on the website is exactly the code that GTM requires.

Good luck

Claudia
Google user
6/12/14
Google user
Where should I paste the container code within my template?
 
As far as I understood it should be placed just after the opening of <body>. However in my blogger template I can´t find a proper <body> tag, but this one instead:
<body expr:class='&quot;loading&quot; + data:blog.mobileClass'>
 
Should I place it after this?
 
Thank you in advance
Bidof vic
9/12/14
Bidof vic
Yes.
Google user
9/16/14
Google user
Thanks. That worked.
Faiq Miftahul Amali
1/15/15
Faiq Miftahul Amali
Thank you Claudia...
You have solved my problem
Geovane Gramagol
1/28/15
Geovane Gramagol
Claudia, it doesn't work to me.
I can't update the page and it doesn't publish at Tag Manager
Google user
5/7/15
Google user
Thank you
Biblioteca Esoterica Costa Rica
5/23/15
Biblioteca Esoterica Costa Rica
thanks that always happens in blogger !!
Nishita Reddy
5/29/15
Nishita Reddy
Thank you 
AFA Ayoub
6/1/15
AFA Ayoub
thanks , worked
38 MORE
momed
1/31/19
momed
thank you claudia
Were these replies helpful?
How can we improve them?
 
This question is locked and replying has been disabled. Still have questions? Ask the Help Community.

Badges

Some community members might have badges that indicate their identity or level of participation in a community.

 
Expert - Google Employee — Googler guides and community managers
 
Expert - Community Specialist — Google partners who share their expertise
 
Expert - Gold — Trusted members who are knowledgeable and active contributors
 
Expert - Platinum — Seasoned members who contribute beyond providing help through mentoring, creating content, and more
 
Expert - Alumni — Past members who are no longer active, but were previously recognized for their helpfulness
 
Expert - Silver — New members who are developing their product knowledge
Community content may not be verified or up-to-date. Learn more.

Levels

Member levels indicate a user's level of participation in a forum. The greater the participation, the higher the level. Everyone starts at level 1 and can rise to level 10. These activities can increase your level in a forum:

  • Post an answer.
  • Having your answer selected as the best answer.
  • Having your post rated as helpful.
  • Vote up a post.
  • Correctly mark a topic or post as abuse.

Having a post marked and removed as abuse will slow a user's advance in levels.

View profile in forum?

To view this member's profile, you need to leave the current Help page.

Report abuse in forum?

This comment originated in the Google Product Forum. To report abuse, you need to leave the current Help page.

Reply in forum?

This comment originated in the Google Product Forum. To reply, you need to leave the current Help page.