Hi @g-mcfadyen,
Here s a sample code. You should add the script tags too in the script input fields.
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-xxxxxxxx"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-xxxxxxxxxx');
</script>
I tried that but it didn’t work. I tried it in the body field too, and that didn’t work either. I’ve tried putting the GA script in a separate JS file and using the head field to call that – that didn’t work either.
When I first installed the plugin, the head field contained some example script which looked like it called a specific function, which I’m presuming is included in the plugin?
I see this in the <head> region –
<script type=’text/javascript’>
/* <![CDATA[ */
var Cli_Data = {“nn_cookie_ids”:[“GA1.2.2104776523.XXXXXXXXXX”,”GA1.2.1791343158.XXXXXXXXXX”,”1″],”cookielist”:[]};
var log_object = {“ajax_url”:”https:\/\/mydomain.com\/wp-admin\/admin-ajax.php”};
/* ]]> */
</script>
These details correspond to the non-necessary cookie IDs/Values for the site, that I’ve added to the Cookie List. However, no matter what I add to the HEAD field, the <head> HTML does not change.
Just to add, mydomain is not yet on https…
-
This reply was modified 6 years, 2 months ago by
g-mcfadyen.
Hi @g-mcfadyen,
We require the site URL to check it further.
Hi @g-mcfadyen,
We suspect there is some cache implementation in place in your site which is causing the trouble.