Filter to override Publish date not working
-
Hi,
I’ve this brand new post: [ redundant link removed ] which doesn’t have any Revisions/updations.
Still Its showing same date as Updated & Published.
My code goes like this:<p><?php if ( function_exists( 'get_the_last_modified_info' ) ) { $updated_date = get_the_last_modified_info(); } if($updated_date): echo 'UPDATED: '.$updated_date.' / '; endif; echo 'PUBLISHED: '.get_the_date(); ?></p>
I’ve included the filter:
function override_time_diff() { return '86400'; // 86400 seconds i.e. 24 hours, set it according to your need } add_filter( 'wplmi_date_time_diff_post', 'override_time_diff' ); // for posts add_filter( 'wplmi_date_time_diff_page', 'override_time_diff' ); // for pages
but it doesn’t work.
Can you please help me troubleshoot this.?Thanks in advance.
- This topic was modified 5 years, 9 months ago by .
- This topic was modified 5 years, 9 months ago by .
The page I need help with: [log in to see the link]
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Filter to override Publish date not working’ is closed to new replies.