Harvy Gangyan Posted December 1, 2021 Share Posted December 1, 2021 I am using Prestashop version 1.7.5.1 and trying to add google tag manager code so I can enable tracking. I followed instructions from one of the forum topics (from this forum only) but after I added the codes, my website crashed and it gave me "HTTP ERROR 500". Once I restored the original file, my website worked fine again. Here are the steps I followed: 1. I edited the file /var/www/html/themes/MY_THEME/templates/layouts/layout-both-columns.tpl 2. I added Head Section Code under "<Head>" tag 3. I added Body Section code after <body id="{$page.page_name}" class="{$page.body_classes|classnames}"> Once I do this, the website starts throwing HTTP Error 500 on me. Can someone help me with this issue and suggest me a solution please? Thanks in advance. Link to comment Share on other sites More sharing options...
ComGrafPL Posted December 2, 2021 Share Posted December 2, 2021 Use free module HtmlBox and copy/paste the code in head. Link to comment Share on other sites More sharing options...
JBW Posted December 3, 2021 Share Posted December 3, 2021 Java script code in template files has to be encapsulated in {literal}{/literal} tags Link to comment Share on other sites More sharing options...
Nickz Posted January 3, 2022 Share Posted January 3, 2022 He does not seem to have returned. Link to comment Share on other sites More sharing options...
ottowebs Posted August 23, 2023 Share Posted August 23, 2023 Hello! I am having the same problem, i added the script code to the head in layout-both-columns.tpl with {literal} tags and the noscript right under the body id="{$page.page_name}" class="{$page.body_classes|classnames}"> without {literal} tags Google tag manager just doesn't seem to read it. Does anyone know the solution to this? Link to comment Share on other sites More sharing options...
Nickz Posted August 23, 2023 Share Posted August 23, 2023 2 hours ago, ottowebs said: Google tag manager just doesn't seem to read it. I think the isssue lies with Google. Some pages the verification is there and visible but the detection of Google fails for weeks now. They have issues which you see when your pages need to be verified again. That usually is a reset. Solution could be to contact Google via Twitter, now X. Link to comment Share on other sites More sharing options...
ottowebs Posted August 23, 2023 Share Posted August 23, 2023 19 minutes ago, Nickz said: I think the isssue lies with Google. Some pages the verification is there and visible but the detection of Google fails for weeks now. They have issues which you see when your pages need to be verified again. That usually is a reset. Solution could be to contact Google via Twitter, now X. Thank you, the problem is: "Google Tag not Found". Do you think the there might be an issue with cookies? Link to comment Share on other sites More sharing options...
Nickz Posted August 23, 2023 Share Posted August 23, 2023 I don't think so. https://support.google.com/tagmanager/thread/207195988/i-keep-getting-a-tag-not-found-error?hl=en Plus they disabled the question. Typical case of cancel culture. The problem remains though. Use Matomo it is much better. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now