Site logo

Archived topic

Can I use Hooks to insert scripts in Header and Footer code of the wordpress

4 replies · Started by Pawanpreet Kaur on December 14, 2020

Viewing posts 1–5 of 5

Hello,

I am using the premium version of the GP and I am more than happy with its performance. So, first of all, thank you very much for the amazing product and service.

I would like to remove the header and footer script inserting plugin from my website so I wanted to know can I insert those scripts using GP Hooks? They are Google analytics, Google Adsense code, Pinterest scripts, Mailchimp script etc.

I am not using a child theme so will any future update remove those hooks or change anything?

Also, will you be adding any post or picture carousel to the theme in future?

Thanks.

Hi there,

I would like to remove the header and footer script inserting plugin from my website so I wanted to know can I insert those scripts using GP Hooks?

Absolutely!

You can use wp_head and wp_footer hook with the hooks element module:
https://docs.generatepress.com/article/hooks-element-overview/

Those won't be erased during updates.

Also, will you be adding any post or picture carousel to the theme in future?

No - those belong in the plugin territory. We try very hard to avoid bloat in GP so only adds options/features that are useful for the majority of our users :)

Hello,

Thank you for your response that takes at least one plugin off my website. :) :)

Hi,

Hey, another question here, please. I found this article to add SM buttons using hooks in GP. Can you please have a look to see if it’s good.

It should work. It's simple yet the links are dynamic so it shouldn't be an issue.

As for it being "good" is something pretty subjective. If you like the design, then go for it. :D

This archived topic is closed to new replies.