Adding extra few lines of code to the Google tag manager, creating the problem

We use cloudflare and thanks to its technology, Website is loading faster.
But the problem is, Google tag manager is not working properly after cloudflare modifies it with few extra lines. We have checked with Google team and they updated us the following.

  • The GA tag is not being fired in page /vps-hosting . This is the primary reason why sessions are not being recorded for campaigns that redirect to this page. (users are still able to reach the website, but GA does not register a session.)

  • The GA tag could be found in the source code of that page, but the tag was customized to include a line that is not originally there as provided by Google. (see attached screenshot customized_ tag.png where I indicate that line.)

  • When testing, I was able to determine that removing the customized code would make the tag fire correctly.

  • Other pages in the website also contain that same customization, although they are affected to a lesser degree.

Based on the above findings, we see that part of the discrepancy comes from the page /vps-hosting , which clearly has an implementation issue. Other pages do not seem to present the exact same behavior, but could be having intermittent issues.

RECOMMENDED NEXT STEPS:

  • It is not clear to which extent other pages are being affected by the same customization. However, we suggest removing all customization that is not in line with the tag as provided by Google on all pages of your website, because this may cause the tag to break intermittently. Our support is always limited when it comes to non-standard implementations.

My Question:
I want to see the Google tags as it is, without any modification. What can be done ?
Please help me

If using Rocket Loader, try to Disable Rocket Loader at Cloudflare, or try with adding a specific attribute to the JS resources to make Rocket loader ignore them as described here:

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.