- This topic has 7 replies, 3 voices, and was last updated 3 months, 4 weeks ago by
David.
-
AuthorPosts
-
September 18, 2020 at 1:01 pm #1449195
Alessio
(old support topic: https://generatepress.com/forums/topic/hook-to-add-share-buttons-after-specific-image/)
Hey,
I’d like to have a different featured image for the blog page and for the posts page. So far, I’ve done it manually, but that doesn’t allow me to add social sharing buttons (via hooks) under the (manually created) featured image.
Example:
Featured image on the blog-page:
Different featured image on the post itself:
Do you understand what I mean?
Thank you for the awesome support, by the way 🙂
September 18, 2020 at 1:34 pm #1449226Leo
StaffCustomer SupportHi Alessio,
The featured image option is a WordPress core function and I don’t think it allows this modification unfortunately.
The only workaround I can think of is to hide the default featured image on single posts in the customizer:
https://docs.generatepress.com/article/adjusting-the-featured-images/Then manually add in the static image as the featured image at the top of your post.
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 24, 2020 at 1:42 am #1456524Alessio
Hi Leo,
sorry for the late reply. I’ve already done what you suggested, but that way I cannot add share buttons under the featured image under the hook, because it’s a manual image.
September 24, 2020 at 8:14 am #1457189David
StaffCustomer SupportHi there,
you may want to consider adding a Custom Field to your posts which can be used to hold the secondary image. Which can then be hooked in with your social share icons.
ACF makes that possible:
https://www.advancedcustomfields.com/resources/image/
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 29, 2020 at 8:48 am #1464058Alessio
Hi David,
that’s an interesting idea, I’ll try it out! Do you know if this is also possible with the custom fields already integrated in the latest WordPress version? Also, how big will the performance impact be(for my visitors) with ACF?
Thank you!
September 29, 2020 at 8:56 am #1464068David
StaffCustomer SupportYou can use the built in Custom Fields, but you would need to add a URL for the image wherase ACF provides an Image Attachment meta box.
Performance wise i cannot see this option in ACF making any noticeable difference.
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 30, 2020 at 6:42 am #1465236Alessio
Alright, I’ll give ACF a try, thank you!
September 30, 2020 at 7:14 am #1465277David
StaffCustomer SupportYou’re welcome
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/ -
AuthorPosts
- You must be logged in to reply to this topic.