Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

confirming property for google seach console broken since 2.6.7 #53

Open
elysian-design opened this issue Apr 4, 2024 · 0 comments
Open

Comments

@elysian-design
Copy link

elysian-design commented Apr 4, 2024

during the improvement from #50 the code was enhanced with a new script tag in front of the <noscript> tag. This changes the code produced in the final page.

Current code output:

    <body>

    <script>
        function gtmPush() {
            window.dataLayer.push({...}});
        }
        addEventListener("load", gtmPush);
    </script>
    <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=XXX-XXXXXX" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

Beforehand it was:

    <body>

    <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=XXX-XXXXXX" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

On confirming a property for google seach console via tag manager, the generated tag manager code is not recognized properly, since the <noscript>tag is not following the <body> tag immediately.

See: https://support.google.com/webmasters/answer/9008080#google_tag_manager_verification&zippy=%2Ccontainer-snippet-in-google-tag-manager

I think the <script> tag should be placed after the <noscript> tag.

@elysian-design elysian-design changed the title confirming property for google seach console broken sind 2.6.7 confirming property for google seach console broken since 2.6.7 Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant