-
AuthorPosts
-
March 18, 2021 at 12:30 pm #1288952
I need a blog grid with all the information from the posts.
I will show each one of them with:
Category
Image
Author
Title
Excerpt
Read moreIn that order to then style it as needed.
From the builder I added Blog Posts and select as grid, but all the extra info is missing. How can I have everything and not just “title and excerpt + read more”.
Thanks.
March 24, 2021 at 1:05 pm #1290096Anything about this?
Thanks.
March 25, 2021 at 4:49 pm #1290407Hi peterolle,
We apologize for the delayed response, please do the following:
1. (skip this step if you have a child theme) Download and use a child theme. You can download and find instructions on how to use it here: https://kriesi.at/documentation/enfold/child-theme/
2. Follow the steps provided in: https://kriesi.at/documentation/enfold/intro-to-layout-builder/#add-elements-to-alb
3. Copy wp-content > themes > enfold > config-templatebuilder > avia-shortcodes > postslider folder to wp-content > themes > enfold-child > shortcodes folder.
4. Edit postslider.php in the child theme and replace with this code: https://pastebin.com/sN4d76MbHope this helps.
Best regards,
Nikko- This reply was modified 3 years, 8 months ago by Nikko. Reason: fix link
March 30, 2021 at 4:09 pm #1291390Thank you Nikko!
Can you please share what was added and in which lines? As you know there are other modifications I have in that file, so knowing the changes will help here.
Thanks.
March 31, 2021 at 7:49 am #1291502Hi peterolle,
You’re welcome :)
This is based on Enfold 4.8.1 postslider.php file (line numbers are based on original code without any of the code removed/replaced):
Line 790 is removed:$output .= $thumbnail ? "<a href='{$link}' data-rel='slide-" . avia_post_slider::$slide . "' class='slide-image' title='{$image_link_title}'>{$thumbnail}</a>" : '';
Line 868-872 is removed:
// elegant style if( ( strpos( $new_blogstyle, 'modern-blog' ) === false ) && ( $new_blogstyle != '' ) ) { $output .= $meta_out; }
and is replaced with:
$output .= $meta_out; $output .= $thumbnail ? "<a href='{$link}' data-rel='slide-" . avia_post_slider::$slide . "' class='slide-image' title='{$image_link_title}'>{$thumbnail}</a>" : '';
Line 894-898 is removed:
// modern business style if( ( strpos( $new_blogstyle, 'modern-blog' ) !== false ) && ( $new_blogstyle != '' ) ) { $output .= $meta_out; }
Line 905-924 is removed:
if( ( $show_meta && ! empty( $excerpt ) ) || in_array( $show_meta_data, array( 'always', 'on_empty_content' ) ) ) { $meta = "<div class='slide-meta'>"; if ( $commentCount != '0' || comments_open( $the_id ) && $entry->post_type != 'portfolio' ) { $link_add = $commentCount === '0' ? '#respond' : '#comments'; $text_add = $commentCount === '1' ? __( 'Comment', 'avia_framework' ) : __( 'Comments', 'avia_framework' ); $meta .= "<div class='slide-meta-comments'><a href='{$link}{$link_add}'>{$commentCount} {$text_add}</a></div><div class='slide-meta-del'>/</div>"; } $markup = avia_markup_helper( array( 'context' => 'entry_time', 'echo' => false, 'id' => $the_id, 'custom_markup' => $custom_markup ) ); $meta .= "<time class='slide-meta-time updated' $markup>" . get_the_time( get_option( 'date_format' ), $the_id ) . '</time>'; $meta .= '</div>'; if( strpos( $blogstyle, 'elegant-blog' ) === false ) { $output .= $meta; $meta = ''; } }
and is replaced with:
$meta = "<div class='slide-meta'>"; $meta .= "<div class='slide-meta-author'>"; $meta .= get_the_author_meta( 'display_name', $entry->post_author ); $meta .= '</div>'; $meta .= '</div>'; $output .= $meta;
Line 931-936 is removed:
$output .= '<footer class="entry-footer">'; if( ! empty( $meta ) ) { $output .= $meta; } $output .= '</footer>';
Best regards,
Nikko -
AuthorPosts
- You must be logged in to reply to this topic.