Archived topic
Create header.php and footer.php in child theme
5 replies · Started by Soumyadip on November 19, 2018
Hi tom, how can i Create header.php and footer.php in child theme because everytime i update the theme all my script on header.php (google auto ads) and footer.php(amazon ads one link) are removed.
Plz let me know the step by step process for this.. because the child theme has only function.php
Hi there,
alternatively you could just add them to a Hook Element:
https://docs.generatepress.com/article/hooks-element-overview/
If not here is the documentation on adding a child theme.
ok thanks, but please let me know which hook element to use
1.For google ads they say to insert the code between the head tags
2. for amazon ads it's before the closing body tag.
So plz let me know which hook use should i use for the 1st (google) and 2nd (amazon)
Googele: wp_header
Amazon: after footer
ok thanks will let you know
You're welcome - keep us posted :)