Wp_head hook not running fast enough

I have a very simple hook test right now:
add_action(‘wp_head’, function(){
echo ‘test’;
});
which I’ve tried in setup.php and actions.php and it always runs too late so my test string ends up showing right after the opening of the tag:

Screen Shot 2021-12-29 at 9.44.16 AM

Any idea how to get this to work? I need to pass one value based on the page being viewed (so that would be easily done in the index.php in php) but I also need to pass more advanced values to my Google Ad Manager that rely on code within my Roots/Sage theme.

Nevermind, sometimes, posting a bug makes you realize what you should search:

1 Like

This topic was automatically closed after 42 days. New replies are no longer allowed.