38
Views
2
Comments
Not able to see the noscript tag of Google Analytics in source code of page
Application Type
Traditional Web

As a part of Google Analytics functionality, added below code  to  <body> tag of the webpage.

<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-XXXXXX"

height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

Used below javascript in the Javascript property of the module 

$(document).ready(function() {  

 $(document.body).prepend('<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=XXXXXX" height="0" width="0" ></iframe></noscript>');

});

But with above changes, I am not able to see the added tag in page source, but could see on page DOM. 

Need help with suggestion on how can I achieve this, so I can see that tag in page source.

2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP
2021-09-08 08-53-27
Archana Gholap

Hi Daniel,

Thanks for reply.

I referred same post to implement it and accordingly done changes in application.

But the issue I was facing was not able to see that <noscript> tag in page source, but can see on page DOM.

Thanks and Regards,

Archana

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.