In order to track keywords in a PPC campaign through Google adwords, I need to put the following code after the opening ‘php’ tag in the header:
The only place I can think to do this is in header.php of the genesis parent them. Is this the right move? Is there any way to make this edit in the child theme so I leave the parent untouched? I see no header.php in Enterprise Pro child theme.
Thanks for the help.
You can try using the Header and Footer Scripts.
Go to Genesis > Theme Settings.
Or you can hook it from your functions file.
Thanks Brad. When I add the code to theme settings, it outputs as text at the top of every page. See screenshot here:
I don’t know how to hook the above mentioned code from the functions file, but that sounds like the right solution. How do I do that?
Is that all the code?
Shouldn’t because that’s where GA code also goes.
Simply hooks plugin is the easiest solution to execute code in a specific position and each hook field explains exactly where the code executes.
Thanks again Brad. I use Google Universal Analytics plugin to insert GA code. I’ll give Genesis Extender a shot at inserting my code in the header section. If that doesn’t work, I’ll try the Simply hooks plugin you mentioned. Appreciate your help.
Brad: I just realized why my code was displaying as text when placed in the the following location: Genesis –> Theme Settings –> Header and Footer Scripts. I had forgotten to wrap the code in <?php ?> tags.
You must be logged in to reply to this topic.
Are you a blogger, web designer, developer, or website owner looking to generate more income?