-
AuthorPosts
-
November 30, 2021 at 5:01 pm #1331029
Hi,
not every blog entries dispaly the date in grid layout.
Any idea what’s wrong?
In privet is the Link to the Blog Page
Thank you vor helping!
December 1, 2021 at 9:43 am #1331095Hey Stefan,
Thank you for the inquiry.
Did you add excerpts to the posts? The post meta info including the date will only display when the post has an excerpt. You can check that in the enfold/config-templatebuilder/avia-shortcodes/postslider/postslider.php line 917.
if( ( $show_meta && ! empty( $excerpt ) ) || in_array( $show_meta_data, array( 'always', 'on_empty_content' ) ) ) { // show post meta here if excerpt is not empty }
Best regards,
IsmaelDecember 2, 2021 at 4:48 pm #1331336Hi Imael,
this is in my .php from Line 905 to 924:
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’>{$commentCount} {$text_add}</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 = ”;
}
}Is this OK?
December 3, 2021 at 7:59 am #1331404Hi,
Yes, it looks fine. And based on that code, the meta info will only display if the excerpt is not empty. You should add an excerpt to the post to display the date info.
Thank you for the update.
Best regards,
IsmaelDecember 3, 2021 at 8:57 am #1331414Hi,
hm, in the other blog pages i also don’t have text in the excerpt fieldAny other idea?
Thank you
December 3, 2021 at 1:32 pm #1331453Hi,
Thank you for the info.
Are you using the Advance Layout Builder (ALB) for some of the posts? For those posts, you may need to add the excerpt manually because the theme will not automatically generate an excerpt based on the content of the builder.
Best regards,
IsmaelDecember 5, 2021 at 1:00 pm #1331591Hi Ismael,
in every blog article i have the field excerpt, and in every blog article the field is empty, but in some article the date is shown in some articles not.
So for Explanation:
i need to show the date in every blog article but i don’t need text in the excerpt field
December 6, 2021 at 6:41 am #1331665Hi,
in every blog article i have the field excerpt,
Thanks for that info. But are you using the Advance Layout Builder for other posts? The excerpt will not display or will not be created automatically based on the post content when the advance builder is active. For those posts, you will have to add the excerpt manually.
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.