I’m using ACF Pro on a custom Genesis site where all blog posts are using ACF fields instead of the default entry post content box. The post content is added by using sub fields within a Flexible Content type. WIthin that Flex Content field is a sub field for text and another for images).
Not sure this makes a difference but I am also using the Genesis Featured Posts plugin as well on certain pages that pulls the post’s featured image, title, author and excerpt. Since I don’t have anything in the default post box, it generates nothing for excerpt. Ultimately I want to replace the excerpt everywhere with the content entered in the ACF Flex Content field I created. Is there a way to set that within my custom child theme that instructs WordPress to pull from that custom field instead of the default content entry box?
I’ve been able to get the below code to work but it selects the last instance of that particular sub field. When creating a post, the user will post content using Flexible content fields for blog_post_text, blog_post_images, and blog_post_gallery. Each post can have multiple. For instance, add one text sub field for the intro, then add an image sub field, then another text sub field, so on and so on. When I use this code, it creates the excerpt, limits it to 100 words, but selects the text from the last blog_post_text sub field added instead of the first.