After reading this article I am a bit confused on what I need to do to install Google Analytics. I have already installed the plugin that comes with X-Theme and I am using a child theme. According to the linked article above the support persons says…
Adding code to function.php is necessary if you are taking the child theme route. However, you can also use Google Analytics plugin.
The second line, “You can ALSO…” is where I am confused. So if I am using a child theme do I need to put in this code into the child themes config.php file in addition to the plugin or does the plugin not need to be used if I am using a child theme?
and is this the EXACT code that needs to go in it?
add_action('wp_head','custom_script');
function custom_script() {
?>
<?php
}
Many thanks,
Houston