Hello from New Zealand, I just want to say that I love my website! Thanks for existing!
I need to add my Google remarketing code. I use the Enfold theme and have already added my analytics code a while ago. I tried some instructions that I found (adding below code with remarketing code in to footer of both functions.php and functions-enfold.php and reuploaded – website went blank)
add_action( ‘wp_footer’, ‘enfold_customization_footerscripts’ );
function enfold_customization_footerscripts() {
?>
<script type = “text/javascript”>
ADDED REMARKETING CODE IN HERE AND REMOVED SCRIPT TAGS
</script>
<?php
}
Thank you kindly for your help!
Hi oldvilladental!
Glad you like Enfold! :)
Login credentials are not working for me, can you please check them once again?
Cheers!
Yigit
will send shortly
Hi!
Code has been added.
Regards,
Josue
Hi, I have the same issue. Where did you place the code? I placed it in the same box as the google analytics but it created an odd extra space at the top of the website.
Where should it go?
Thanks,
Slade
Hi!
Please place your js code in the below script where it say’s “//add you script here” and place the whole block of code in Appearance > Editor > functions.php
// Add custom js
function custom_excerpt(){
?>
<script>
// Add your script here
</script>
<?php
}
add_action('wp_footer', 'custom_excerpt');
Regards,
Vinay
Hi, did this change within the functions.php? I’m trying to add our Google Remarketing Code and can’t find these lines in the functions.php file. I have the most recent version of Enfold, installed today. Thanks
Hi,
It’s not there, the code is meant to be added to the file, if you’re not using a child theme you can use this plugin to store functions like that:
https://wordpress.org/plugins/functionality/
Best regards,
Josue