-
AuthorPosts
-
May 1, 2023 at 4:42 pm #1406101
Hi guys! i need to move post post date from bottom of post to top.
and i need to dates: post creation and post modified.
how to do it?May 2, 2023 at 2:52 am #1406134Hey mischael1,
Thank you for the inquiry.
We may need to inspect the site in order to provide the proper modifications. Please provide the site URL in the private field.
To display the modified date, you have to edit the includes > loop-index.php file around line 447 and use the get_the_modified_date function.
$meta_time .= apply_filters( 'avf_loop_index_meta_time', get_the_time( get_option( 'date_format' ) ), $current_post['the_id'], get_option( 'date_format' ) );
Please check the following thread for more info.
// https://kriesi.at/support/topic/enfold-latest-portfolio-widget-publish-time/#post-1302798
Best regards,
IsmaelMay 18, 2023 at 2:00 pm #1407841Sorry for delay.
Check private field for site accesses.If you pleased I will expand the question.
I need both dates under title: creation date and last modified date with little text before each.On screenshot under title is categories, but I’m not sure, possible i will hide it by theme blog setting (if it matter).
May 22, 2023 at 12:41 am #1408099Hi,
Thank you for your patience and the link to your site, I assumed that you wanted the creation date and last modified date in a single line so I added this to your child theme functions.php:function add_postdate_after_single_post_titles() { ?> <script> window.addEventListener('DOMContentLoaded', function() { (function($){ var publishdate = '<?php echo get_the_time(get_option('date_format'));?>'; var modifieddate = '<?php echo get_the_modified_date( get_option('date_format'));?>'; $('#top.single-post').each(function () { $('<time class="date-container minor-meta updated">Publish Date: ' + publishdate + ' Modified Date: ' + modifieddate + '</time>').css({'top':'-25px','position':'relative'}).insertAfter('.blog-categories.minor-meta'); }); })(jQuery); }); </script> <?php } add_action('wp_footer', 'add_postdate_after_single_post_titles');
Best regards,
Mike -
AuthorPosts
- You must be logged in to reply to this topic.