How to Display the Last Updated Date in Newspaper WordPress Theme


Display the Last Updated Date in newspaper WordPress theme

Display the Last Updated Date in newspaper WordPress Theme

Recently we publish a Tutorial for How to Show Last Updated Date in Schema WordPress theme.This tutorial we are going to Learn about How to Display the Last Updated Date in Newspaper WordPress Theme.Already I explain its advantages in My previous blog post.

How to Display the Last Updated Date in Newspaper WordPress Theme?

This one Display Last Updated Date in Homepage on Newspaper WordPress theme

  • Open your Web hosting Cpanel ( don’t edit the theme from WordPress admin panel)
  • Open File manager
  • Cloud user login your FTP/SFTP account
  • Go to wp-content/Newspaper/includes/wp_booster/
  • Open td_module.php file  
  • Just open the File and Use CTRL +F to find the Below code (Use Code Editor to Modify your WordPress theme) you can Found this on 153rd line
$td_article_date_unix = get_the_time('U', $this->post->ID);

 

  • Replace this line with the Below Last Updated Function Code
$td_article_date_unix = get_the_modified_time('U', $this->post->ID);
  • Now Find this below line (on 155th line) for add Modified Date Message – you can also add your own
$buffy .= '<time class="entry-date updated td-module-date' . $visibility_class . '" datetime="' . date(DATE_W3C, $td_article_date_unix) . '" >' . get_the_time(get_option('date_format'), $this->post->ID) . '</time>';
  • Replace it with this Below code
$buffy .= 'Last Updated: <time class="entry-date updated td-module-date' . $visibility_class . '" datetime="' . date(DATE_W3C, $td_article_date_unix) . '" >' . get_the_modified_time(get_option('date_format'), $this->post->ID) . '</time>';

  • If you want to Display Own Date Update Message replace Last Updated: With your Custom Message

Display the Last Updated Date in newspaper WordPress theme

  • After all, Edits save the File td_module.php Clear cache & check your Home pages

Output

Display the Last Updated Date in newspaper WordPress theme

  • Successfully we added the Last Updated Date Feature in Newspaper WordPress theme Homepages.

How to Display Last Updated date in Newspaper WordPress Theme Single Posts?

  • Folders & Modification are same as Above Method, but Files are Different
  • Open wp-content/Newspaper/includes/wp_booster/
  • Next Open this  File td_module_single_base.php
  • And Find this Below lines on (288 and 290th line)
$td_article_date_unix = get_the_time('U', $this->post->ID);
$buffy .= '<time class="entry-date updated td-module-date' . $visibility_class . '" datetime="' . date(DATE_W3C, $td_article_date_unix) . '" >' . get_the_time(get_option('date_format'), $this->post->ID) . '</time>';
  • Replace it with this below codes
  • For Modified Date and Modified Date Message
$td_article_date_unix = get_the_modified_time('U', $this->post->ID);
$buffy .= 'Last Updated: <time class="entry-date updated td-module-date' . $visibility_class . '" datetime="' . date(DATE_W3C, $td_article_date_unix) . '" >' . get_the_modified_time(get_option('date_format'), $this->post->ID) . '</time>';
  • Modifications are Same as Above Method.File and lines only Differ for this both pages

Display the Last Updated Date in newspaper WordPress theme

Output

Display the Last Updated Date in newspaper WordPress theme

  • Now save the File td_module_single_base.php clear cache and check your Posts it will Display the Last updated Modified Date

From the Editor’s Desk

we have tested this code Personally in Newspaper theme we attach the Output Image from the blog which uses the newspaper WordPress theme. (Note – If you get the New theme update means Just backup the td_module.php and td_module_single_base.php files Before Update because new theme update overwrites the current theme customization)

Disclaimer

We are Purchasing this theme From Themeforest and Use Orginal and Licensed Version of Newspaper WordPress theme.No themes Files are Attaching in this Post.This Topic only Covers the Display Last Updated date in Newspaper WordPress theme.Buy Orginal Products & Support the Developers.

Hope this Guide Help you to add the Display the Last Updated Date in newspaper WordPress theme.If you Have to Doubts in this Topic Feel Free to Comment here, I will Guide you.

How to Guides

 



Was this article helpful?
Thanks!

Your feedback helps us improve Allwebtuts.com