var gtmId = containerId;
var headTag = "<!-- Google Tag Manager -->
\
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
\
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
\
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
\
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
\
})(window,document,'script','dataLayer','" + gtmId + "');</script>
\
<!-- End Google Tag Manager -->"
var bodyTag = "<!-- Google Tag Manager (noscript) -->
"
var emailBody1 = "
\
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=" + gtmId + ""
\
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
\
<!-- End Google Tag Manager (noscript) -->
Your Google Tag Manager container is now ready to install.\n\nPlease insert the following code just after the opening head tag of your website:
" + headTag;
var emailBody2 = "
\n\nPlease insert the following code just after the opening body tag:
\n\n" + bodyTag; var options = { 'htmlBody': emailBody1 + emailBody2 } GmailApp.sendEmail(paramsHardcoded.customerEmail, "Your Google Tag Manager Container", "This email contains your tracking code for online marketing, please open it on an email client that supports HTML.", options);