Home › Forums › Support › Adding Hook in the very top of This topic has 3 replies, 2 voices, and was last updated 6 years, 10 months ago by Tom. Viewing 4 posts - 1 through 4 (of 4 total) Author Posts May 20, 2017 at 9:02 am #321246 Will Hi there, I need some code injecting at the top of all the other CSS / Javascript / Title / Meta tags in the header in order to run Google Optimize efficiently. Please can you help with this? I used the standard GP Hook but it loads last in the head tag May 20, 2017 at 9:10 am #321254 TomLead Developer Lead Developer Hi Will, You would do this: add_action( 'wp_head','tu_wp_head_first', 0 ); function tu_wp_head_first() { ?> Your stuff in here <?php } Adding PHP: https://docs.generatepress.com/article/adding-php/ May 20, 2017 at 9:15 am #321259 Will Hi Tom, As a function.php or in the GP Hook? May 20, 2017 at 9:29 am #321279 TomLead Developer Lead Developer Like this: https://docs.generatepress.com/article/adding-php/ Author Posts Viewing 4 posts - 1 through 4 (of 4 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In