
Tagged: excerpt, schmidtgrafisk
-
AuthorPosts
-
April 14, 2025 at 6:23 pm #1481321
Hi, I’m looking to build a page that looks like a webshop using blog post as a product page.
I’v had a look at post slider to show and short products but it just has one row, is there way to build the page with multiple rows and columns to show all the product posts.I really hope this is possible
Thanks Alan ;)
April 15, 2025 at 5:20 am #1481351Hey Alan,
Thank you for the inquiry.
Have you tried using the Product Grid element? You can also use the Blog Posts element with the Blog Style set to Grid Layout, but it will require some adjustments to display elements such as the Add to Cart button. Let us know if you need more info.
Best regards,
IsmaelApril 15, 2025 at 5:34 pm #1481388Hey Ismael
Thanks got that one ;)
I’m designing the post using the Advanced builder, when using the Advanced builder I’m only able to show
– The image
– Title
– Read more
– The date.I’d like to show
– The image
– Title and Excerpt + Read moreI don’t want to show the date and the category
Please have a look at the linked image
Thanks ;)
April 16, 2025 at 6:23 am #1481413Hi,
Thank you for the update.
You can disable the Blog Post Category in Enfold > Blog Layout > Blog Meta Elements to hide the post categories. If you’re using the ALB for the post, make sure to manually define the excerpt in the Excerpt field, otherwise, it won’t display any excerpt.
Best regards,
IsmaelApril 16, 2025 at 9:43 am #1481423Hi Ismael,
I’v tried but I can’t get to look right
This is what I’v done
– Post is build with the Advanced Layout BuilderBlog Layout settings
– Blog Layout is set to – Use the advance layout build to…..
– Blog Meta Elements – Nothing is selected all is offThe Blog Post element settings on the page
– Blog Style – Grid Layout
– Define Blog Grid layout – Only excerpt + Read More LinkPlease have a look at the link below
Thanks ;)
-
This reply was modified 2 days, 16 hours ago by
Schmidtgrafisk.
-
This reply was modified 2 days, 16 hours ago by
Schmidtgrafisk.
April 17, 2025 at 3:16 pm #1481517Dear @Ismael,
However, I don’t fully understand the part regarding the manual excerpt.
I’ve added the following snippet, and now the excerpt correctly shows the content from the first ALB text block ([av_textblock]), even if the manual excerpt field is empty:
add_filter( 'get_the_excerpt', 'custom_alb_excerpt_fallback', 20, 2 ); function custom_alb_excerpt_fallback( $excerpt, $post ) { if ( ! $excerpt && $post instanceof WP_Post ) { $raw_content = $post->post_content; // Extrahiere den ersten ALB Textblock (Shortcode [av_textblock]) if ( preg_match( '/\[av_textblock.*?\](.*?)\[\/av_textblock\]/s', $raw_content, $matches ) ) { $inner = wp_strip_all_tags( $matches[1] ); // HTML entfernen $excerpt = wp_trim_words( $inner, 30, '...' ); // Kürze auf 30 Wörter } } return $excerpt; }
Would you consider this a valid solution? Or is there any reason not to use such a fallback?
Best HPApril 18, 2025 at 6:36 am #1481564 -
This reply was modified 2 days, 16 hours ago by
-
AuthorPosts
- You must be logged in to reply to this topic.