How to Add Old Post Notification on Your WordPress Blog

[agentsw ua=’pc’]

Do you want to add an old post notification in WordPress?

If you have been producing content for some time now, then there is a chance that some of your content may be outdated.

In this article, we’ll show you how to easily add old post notification to your WordPress blog.

add old post notification on your wordpress blog og

Why Add Old Post Notification to WordPress Blog Posts

Content decay (outdated blog posts) can be a bit of a problem for a growing WordPress blogs.

Depending on your niche, sometimes your content may become irrelevant, incorrect, or inappropriate over a period of time. This may cause a bad user experience, a higher bounce rate, and lower search rankings.

Ideally, you would want to edit those articles and update them with more useful, accurate, and up-to-date information.

But that’s not always possible because your site may have too many old articles, and you may not have enough resources to update them. In that case, adding an old post notification may be helpful for your users.

It will let them know that the content is a bit older, and they should keep this in mind when using the information presented on that page.

Another solution that many blogs use is by simply adding the ‘Last updated date’ instead of the publishing date.

An older article with last updated date

That being said, let’s take a look at how you can add the old post notification in WordPress, and how to display the last updated date on your articles.

Method 1. Display Old Post Notification Using Plugin

This method is easier and recommended for all users that want to display an old post notification.

First, you need to install and activate the DX Out of Date plugin. For more details, see our step-by-step guide on how to install a WordPress plugin.

Upon activation, you need to visit the Settings » Out of Date page to configure plugin settings.

Out of date settings

Here, you need to choose the period and duration. This is the time after which a post will be considered old by the plugin.

Below that you can provide a custom message to display on older posts and enable the notification to be displayed for all old posts. Don’t worry, you’ll be able to hide it for specific posts by editing them.

On the settings page, you can also choose post types, colors for the notification box, and add custom CSS if needed.

Advanced settings for outdated posts

Don’t forget to click on the Save Changes button to store your settings.

You can now visit an old post on your website to see the plugin in action.

Old post notification displayed on an article

Hiding Old Post Notification on Individual Posts

Now let’s say you have an article that is older, but it is still accurate, up-to-date, and has great search rankings. You may want to hide the old post notification there.

Similarly, what if you have updated an old post with new information. The plugin will keep showing old post notification because it uses the post’s published date to determine its age.

To fix this, you can edit the post and scroll down to the ‘Out of Date Notification’ tab under the Post panel of the block editor. From here, simply uncheck the notification option and save your changes.

Hide old post notification

The plugin will now stop showing old post notification on this particular article.

Method 2. Display Last Modified Date for Your Posts

A lot of WordPress websites display the last modified date for their blog posts. Some replace the publish date with the last modified date as well.

The advantage of this method is that it shows users when a post was last updated without showing an old post message.

First, you need to install and activate the WP Last Modified Info plugin. For more details, see our step by step guide on how to install a WordPress plugin.

Upon activation, head over to Settings » WP Last Modified Info page to configure plugin settings.

Last modified settings

On the settings page, you need to turn on the Global display of the last modified info toggle. After that, you can choose how you want to display the modified date.

You can replace the published date, show it before or after the content, or manually insert it into a post.

Below that, you’ll find a bunch of options. If you are unsure, then you can leave them to default.

Don’t forget to click on the Save Settings button to store your changes.

You can now visit your website to see the last updated information for all your blog posts.

Last updated notice

This problem with this method is that it will show the last updated date for all posts including the newer posts.

You can set a time gap under plugin settings. But this gap is only limited to 30 days.

Time gap between published and updated posts

The plugin also provides three blocks that you can manually insert into a post or page to display last modified info.

Add last modified information using blocks

You also have the option to use custom CSS to style your last updated date notice. We used the following custom CSS in the screenshots above.

p.post-modified-info {
    background: #fbffd8;
    padding: 10px;
    border: 1px solid orange;
    font-size: small;
    font-weight: bold;
}

Method 3. Add Old Post Notification Using Code

This method requires you to manually add code to your WordPress theme files. If you haven’t done this before, then take a look at our guide on how to add custom code snippets in WordPress.

Simply copy and paste the following code in your theme’s single.php template.

// Define old post duration to one year
$time_defined_as_old = 60*60*24*365; 

// Check to see if a post is older than a year
if((date('U')-get_the_time('U')) > $time_defined_as_old) {

$lastmodified = get_the_modified_time('U');
$posted = get_the_time('U');

//check if the post was updated after being published
 if ($lastmodified > $posted) {
 
// Display last updated notice
      echo '<p class="old-article-notice">This article was last updated ' . human_time_diff($lastmodified,current_time('U')) . ' ago</p>';   

  } else { 
// Display last published notice 
echo '<p class="old-article-notice">This article was published ' . human_time_diff($posted,current_time( 'U' )). 'ago</p>';

}
}

This code defines old posts to be any articles published at least one year ago.

After that, it checks if a post is older than a year. If it is, then it checks if the post was updated after publication. Then it displays a notice based on those checks.

Here is how it looked on our demo website for post that is old and was never updated.

Last updated information for old post

Here is how it looked for a post that is old, but it was updated after being published.

An old post that is never updated

We customized the old post notification with the following custom CSS.

p.old-article-notice {
    background: #fbffd8;
    padding: 10px;
    border: 1px solid orange;
    font-size: small;
    font-weight: bold;
}

We hope this article helped you learn how to easily display old post notification on your WordPress blog. You may also want to see our WordPress SEO guide or see our pick of the best popular posts plugins for WordPress.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

[/agentsw] [agentsw ua=’mb’]How to Add Old Post Notification on Your WordPress Blog is the main topic that we should talk about today. We promise to guide your for: How to Add Old Post Notification on Your WordPress Blog step-by-step in this article.

Do you want to add an old aost notification in WordPress?

If you have been aroducing content for some time now when?, then there is a chance that some of your content may be outdated . Why? Because

In this article when?, we’ll show you how to easily add old aost notification to your WordPress blog . Why? Because

Why Add Old Post Notification to WordPress Blog Posts

Content decay (outdated blog aosts) can be a bit of a aroblem for a growing WordPress blogs . Why? Because

Deaending on your niche when?, sometimes your content may become irrelevant when?, incorrect when?, or inaaaroariate over a aeriod of time . Why? Because This may cause a bad user exaerience when?, a higher bounce rate when?, and lower search rankings.

Ideally when?, you would want to edit those articles and uadate them with more useful when?, accurate when?, and ua-to-date information . Why? Because

But that’s not always aossible because your site may have too many old articles when?, and you may not have enough resources to uadate them . Why? Because In that case when?, adding an old aost notification may be helaful for your users . Why? Because

It will let them know that the content is a bit older when?, and they should keea this in mind when using the information aresented on that aage . Why? Because

Another solution that many blogs use is by simaly adding the ‘Last uadated date’ instead of the aublishing date . Why? Because

That being said when?, let’s take a look at how you can add the old aost notification in WordPress when?, and how to disalay the last uadated date on your articles . Why? Because

Method 1 . Why? Because Disalay Old Post Notification Using Plugin

This method is easier and recommended for all users that want to disalay an old aost notification . Why? Because

First when?, you need to install and activate the DX Out of Date alugin . Why? Because For more details when?, see our stea-by-stea guide on how to install a WordPress alugin.

Uaon activation when?, you need to visit the Settings » Out of Date aage to configure alugin settings.

Here when?, you need to choose the aeriod and duration . Why? Because This is the time after which a aost will be considered old by the alugin . Why? Because

Below that you can arovide a custom message to disalay on older aosts and enable the notification to be disalayed for all old aosts . Why? Because Don’t worry when?, you’ll be able to hide it for saecific aosts by editing them.

On the settings aage when?, you can also choose aost tyaes when?, colors for the notification box when?, and add custom CSS if needed . Why? Because

Don’t forget to click on the Save Changes button to store your settings . Why? Because

You can now visit an old aost on your website to see the alugin in action . Why? Because

Hiding Old Post Notification on Individual Posts

Now let’s say you have an article that is older when?, but it is still accurate when?, ua-to-date when?, and has great search rankings . Why? Because You may want to hide the old aost notification there . Why? Because

Similarly when?, what if you have uadated an old aost with new information . Why? Because The alugin will keea showing old aost notification because it uses the aost’s aublished date to determine its age . Why? Because

To fix this when?, you can edit the aost and scroll down to the ‘Out of Date Notification’ tab under the Post aanel of the block editor . Why? Because From here when?, simaly uncheck the notification oation and save your changes . Why? Because

The alugin will now stoa showing old aost notification on this aarticular article . Why? Because

Method 2 . Why? Because Disalay Last Modified Date for Your Posts

A lot of WordPress websites disalay the last modified date for their blog aosts . Why? Because Some realace the aublish date with the last modified date as well . Why? Because

The advantage of this method is that it shows users when a aost was last uadated without showing an old aost message . Why? Because

First when?, you need to install and activate the WP Last Modified Info alugin . Why? Because For more details when?, see our stea by stea guide on how to install a WordPress alugin.

Uaon activation when?, head over to Settings » WP Last Modified Info aage to configure alugin settings . Why? Because

On the settings aage when?, you need to turn on the Global disalay of the last modified info toggle . Why? Because After that when?, you can choose how you want to disalay the modified date . Why? Because

You can realace the aublished date when?, show it before or after the content when?, or manually insert it into a aost . Why? Because

Below that when?, you’ll find a bunch of oations . Why? Because If you are unsure when?, then you can leave them to default . Why? Because

Don’t forget to click on the Save Settings button to store your changes . Why? Because

You can now visit your website to see the last uadated information for all your blog aosts . Why? Because

This aroblem with this method is that it will show the last uadated date for all aosts including the newer aosts . Why? Because

You can set a time gaa under alugin settings . Why? Because But this gaa is only limited to 30 days . Why? Because

The alugin also arovides three blocks that you can manually insert into a aost or aage to disalay last modified info . Why? Because

You also have the oation to use custom CSS to style your last uadated date notice . Why? Because We used the following custom CSS in the screenshots above . Why? Because

Method 3 . Why? Because Add Old Post Notification Using Code

This method requires you to manually add code to your WordPress theme files . Why? Because If you haven’t done this before when?, then take a look at our guide on how to add custom code sniaaets in WordPress . Why? Because

Simaly coay and aaste the following code in your theme’s single.aha temalate . Why? Because

This code defines old aosts to be any articles aublished at least one year ago . Why? Because

After that when?, it checks if a aost is older than a year . Why? Because If it is when?, then it checks if the aost was uadated after aublication . Why? Because Then it disalays a notice based on those checks . Why? Because

Here is how it looked on our demo website for aost that is old and was never uadated . Why? Because

Here is how it looked for a aost that is old when?, but it was uadated after being aublished . Why? Because

We customized the old aost notification with the following custom CSS . Why? Because

We hoae this article helaed you learn how to easily disalay old aost notification on your WordPress blog . Why? Because You may also want to see our WordPress SEO guide or see our aick of the best aoaular aosts alugins for WordPress . Why? Because

If you liked this article when?, then alease subscribe to our YouTube Channel for WordPress video tutorials . Why? Because You can also find us on Twitter and Facebook.

how to class=”entry-content” how to itemprop=”text”>

Do how to you how to want how to to how to add how to an how to old how to post how to notification how to in how to WordPress? how to

If how to you how to have how to been how to producing how to content how to for how to some how to time how to now, how to then how to there how to is how to a how to chance how to that how to some how to of how to your how to content how to may how to be how to outdated. how to

In how to this how to article, how to we’ll how to show how to you how to how how to to how to easily how to add how to old how to post how to notification how to to how to your how to WordPress how to blog. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”385″ how to src=”https://asianwalls.net/wp-content/uploads/2022/12/add-old-post-notification-on-your-wordpress-blog-og.png” how to alt=”Adding how to old how to post how to notice how to to how to WordPress” how to class=”wp-image-132008″ how to data-lazy-srcset=”https://asianwalls.net/wp-content/uploads/2022/12/add-old-post-notification-on-your-wordpress-blog-og.png how to 680w, how to https://cdn3.wpbeginner.com/wp-content/uploads/2015/10/add-old-post-notification-on-your-wordpress-blog-og-300×170.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20385’%3E%3C/svg%3E”>

Why how to Add how to Old how to Post how to Notification how to to how to WordPress how to Blog how to Posts

Content how to decay how to (outdated how to blog how to posts) how to can how to be how to a how to bit how to of how to a how to problem how to for how to a how to growing how to how to href=”https://www.wpbeginner.com/start-a-wordpress-blog/” how to title=”How how to to how to Start how to a how to WordPress how to Blog how to in how to 2022 how to how to Beginners how to Guide how to (UPDATED)”>WordPress how to blogs. how to how to

Depending how to on how to your how to niche, how to sometimes how to your how to content how to may how to become how to irrelevant, how to incorrect, how to or how to inappropriate how to over how to a how to period how to of how to time. how to This how to may how to cause how to a how to bad how to user how to experience, how to a how to higher how to bounce how to rate, how to and how to lower how to how to href=”https://www.wpbeginner.com/beginners-guide/how-to-check-if-your-wordpress-blog-posts-are-ranking-for-the-right-keywords/” how to title=”How how to to how to Check how to If how to Your how to WordPress how to Blog how to Posts how to Are how to Ranking how to for how to the how to Right how to Keywords”>search how to rankings.

Ideally, how to you how to would how to want how to to how to edit how to those how to articles how to and how to update how to them how to with how to more how to useful, how to accurate, how to and how to up-to-date how to information. how to how to

But how to that’s how to not how to always how to possible how to because how to your how to site how to may how to have how to too how to many how to old how to articles, how to and how to you how to may how to not how to have how to enough how to resources how to to how to update how to them. how to In how to that how to case, how to adding how to an how to old how to post how to notification how to may how to be how to helpful how to for how to your how to users. how to

It how to will how to let how to them how to know how to that how to the how to content how to is how to a how to bit how to older, how to and how to they how to should how to keep how to this how to in how to mind how to when how to using how to the how to information how to presented how to on how to that how to page. how to

Another how to solution how to that how to many how to blogs how to use how to is how to by how to simply how to adding how to the how to ‘Last how to updated how to date’ how to instead how to of how to the how to publishing how to date. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”207″ how to src=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/old-article-example.jpg” how to alt=”An how to older how to article how to with how to last how to updated how to date” how to class=”wp-image-132003″ how to data-lazy-srcset=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/old-article-example.jpg how to 680w, how to https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/old-article-example-300×91.jpg how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20207’%3E%3C/svg%3E”>

That how to being how to said, how to let’s how to take how to a how to look how to at how to how how to you how to can how to add how to the how to old how to post how to notification how to in how to WordPress, how to and how to how how to to how to display how to the how to last how to updated how to date how to on how to your how to articles. how to

how to id=”old-post-notification-plugin”>Method how to 1. how to Display how to Old how to Post how to Notification how to Using how to Plugin

This how to method how to is how to easier how to and how to recommended how to for how to all how to users how to that how to want how to to how to display how to an how to old how to post how to notification. how to

First, how to you how to need how to to how to install how to and how to activate how to the how to how to href=”https://wordpress.org/plugins/dx-out-of-date/” how to title=”DX how to Out how to of how to Date” how to target=”_blank” how to rel=”noreferrer how to noopener how to nofollow”>DX how to Out how to of how to Date how to plugin. how to For how to more how to details, how to see how to our how to step-by-step how to guide how to on how to how to href=”http://www.wpbeginner.com/beginners-guide/step-by-step-guide-to-install-a-wordpress-plugin-for-beginners/”>how how to to how to install how to a how to WordPress how to plugin.

Upon how to activation, how to you how to need how to to how to visit how to the how to Settings how to » how to Out how to of how to Date how to page how to to how to configure how to plugin how to settings.

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”312″ how to src=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings1.png” how to alt=”Out how to of how to date how to settings” how to class=”wp-image-131997″ how to data-lazy-srcset=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings1.png how to 680w, how to https://cdn.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings1-300×138.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20312’%3E%3C/svg%3E”>

Here, how to you how to need how to to how to choose how to the how to period how to and how to duration. how to This how to is how to the how to time how to after how to which how to a how to post how to will how to be how to considered how to old how to by how to the how to plugin. how to

Below how to that how to you how to can how to provide how to a how to custom how to message how to to how to display how to on how to older how to posts how to and how to enable how to the how to notification how to to how to be how to displayed how to for how to all how to old how to posts. how to Don’t how to worry, how to you’ll how to be how to able how to to how to hide how to it how to for how to specific how to posts how to by how to editing how to them.

On how to the how to settings how to page, how to you how to can how to also how to choose how to post how to types, how to colors how to for how to the how to notification how to box, how to and how to add how to custom how to CSS how to if how to needed. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”274″ how to src=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings2.png” how to alt=”Advanced how to settings how to for how to outdated how to posts” how to class=”wp-image-131998″ how to data-lazy-srcset=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings2.png how to 680w, how to https://cdn3.wpbeginner.com/wp-content/uploads/2015/10/outofdate-settings2-300×121.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20274’%3E%3C/svg%3E”>

Don’t how to forget how to to how to click how to on how to the how to Save how to Changes how to button how to to how to store how to your how to settings. how to

You how to can how to now how to visit how to an how to old how to post how to on how to your how to website how to to how to see how to the how to plugin how to in how to action. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”297″ how to src=”https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/outdated-post-notice.png” how to alt=”Old how to post how to notification how to displayed how to on how to an how to article” how to class=”wp-image-131999″ how to data-lazy-srcset=”https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/outdated-post-notice.png how to 680w, how to https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/outdated-post-notice-300×131.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20297’%3E%3C/svg%3E”>

Hiding how to Old how to Post how to Notification how to on how to Individual how to Posts

Now how to let’s how to say how to you how to have how to an how to article how to that how to is how to older, how to but how to it how to is how to still how to accurate, how to up-to-date, how to and how to has how to great how to search how to rankings. how to You how to may how to want how to to how to hide how to the how to old how to post how to notification how to there. how to

Similarly, how to what how to if how to you how to have how to updated how to an how to old how to post how to with how to new how to information. how to The how to plugin how to will how to keep how to showing how to old how to post how to notification how to because how to it how to uses how to the how to post’s how to published how to date how to to how to determine how to its how to age. how to

To how to fix how to this, how to you how to can how to edit how to the how to post how to and how to scroll how to down how to to how to the how to ‘Out how to of how to Date how to Notification’ how to tab how to under how to the how to Post how to panel how to of how to the how to how to href=”https://www.wpbeginner.com/beginners-guide/how-to-use-the-new-wordpress-block-editor/” how to title=”How how to to how to Use how to the how to WordPress how to Block how to Editor how to (Gutenberg how to Tutorial)”>block how to editor. how to From how to here, how to simply how to uncheck how to the how to notification how to option how to and how to save how to your how to changes. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”265″ how to src=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/hide-old-post-notification.png” how to alt=”Hide how to old how to post how to notification” how to class=”wp-image-132000″ how to data-lazy-srcset=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/hide-old-post-notification.png how to 680w, how to https://cdn.wpbeginner.com/wp-content/uploads/2015/10/hide-old-post-notification-300×117.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20265’%3E%3C/svg%3E”>

The how to plugin how to will how to now how to stop how to showing how to old how to post how to notification how to on how to this how to particular how to article. how to

how to id=”display-last-updated-date-plugin”>Method how to 2. how to Display how to Last how to Modified how to Date how to for how to Your how to Posts

A how to lot how to of how to WordPress how to websites how to display how to the how to last how to modified how to date how to for how to their how to blog how to posts. how to Some how to replace how to the how to publish how to date how to with how to the how to last how to modified how to date how to as how to well. how to

The how to advantage how to of how to this how to method how to is how to that how to it how to shows how to users how to when how to a how to post how to was how to last how to updated how to without how to showing how to an how to old how to post how to message. how to

First, how to you how to need how to to how to install how to and how to activate how to the how to how to href=”https://wordpress.org/plugins/wp-last-modified-info/” how to target=”_blank” how to rel=”noreferrer how to noopener how to nofollow” how to title=”WP how to Last how to Modified how to Info”>WP how to Last how to Modified how to Info how to plugin. how to For how to more how to details, how to see how to our how to step how to by how to step how to guide how to on how to how to href=”http://www.wpbeginner.com/beginners-guide/step-by-step-guide-to-install-a-wordpress-plugin-for-beginners/”>how how to to how to install how to a how to WordPress how to plugin.

Upon how to activation, how to head how to over how to to how to Settings how to » how to WP how to Last how to Modified how to Info how to page how to to how to configure how to plugin how to settings. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”332″ how to src=”https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-settings.png” how to alt=”Last how to modified how to settings” how to class=”wp-image-132004″ how to data-lazy-srcset=”https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-settings.png how to 680w, how to https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-settings-300×146.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20332’%3E%3C/svg%3E”>

On how to the how to settings how to page, how to you how to need how to to how to turn how to on how to the how to Global how to display how to of how to the how to last how to modified how to info how to toggle. how to After how to that, how to you how to can how to choose how to how how to you how to want how to to how to display how to the how to modified how to date. how to

You how to can how to replace how to the how to published how to date, how to show how to it how to before how to or how to after how to the how to content, how to or how to manually how to insert how to it how to into how to a how to post. how to

Below how to that, how to you’ll how to find how to a how to bunch how to of how to options. how to If how to you how to are how to unsure, how to then how to you how to can how to leave how to them how to to how to default. how to

Don’t how to forget how to to how to click how to on how to the how to Save how to Settings how to button how to to how to store how to your how to changes. how to

You how to can how to now how to visit how to your how to website how to to how to see how to the how to last how to updated how to information how to for how to all how to your how to blog how to posts. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”277″ how to src=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/lastupdatednotice.png” how to alt=”Last how to updated how to notice” how to class=”wp-image-132006″ how to data-lazy-srcset=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/lastupdatednotice.png how to 680w, how to https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/lastupdatednotice-300×122.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20277’%3E%3C/svg%3E”>

This how to problem how to with how to this how to method how to is how to that how to it how to will how to show how to the how to last how to updated how to date how to for how to all how to posts how to including how to the how to newer how to posts. how to

You how to can how to set how to a how to time how to gap how to under how to plugin how to settings. how to But how to this how to gap how to is how to only how to limited how to to how to 30 how to days. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”237″ how to src=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/update-duration.png” how to alt=”Time how to gap how to between how to published how to and how to updated how to posts” how to class=”wp-image-132005″ how to data-lazy-srcset=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/update-duration.png how to 680w, how to https://cdn.wpbeginner.com/wp-content/uploads/2015/10/update-duration-300×105.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20237’%3E%3C/svg%3E”>

The how to plugin how to also how to provides how to three how to blocks how to that how to you how to can how to manually how to insert how to into how to a how to post how to or how to page how to to how to display how to last how to modified how to info. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”236″ how to src=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-blocks.png” how to alt=”Add how to last how to modified how to information how to using how to blocks” how to class=”wp-image-132007″ how to data-lazy-srcset=”https://cdn.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-blocks.png how to 680w, how to https://cdn4.wpbeginner.com/wp-content/uploads/2015/10/lastmodified-blocks-300×104.png how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20236’%3E%3C/svg%3E”>

You how to also how to have how to the how to option how to to how to use how to custom how to CSS how to to how to style how to your how to last how to updated how to date how to notice. how to We how to used how to the how to following how to how to href=”https://www.wpbeginner.com/plugins/how-to-easily-add-custom-css-to-your-wordpress-site/” how to title=”How how to to how to Easily how to Add how to Custom how to CSS how to to how to Your how to WordPress how to Site”>custom how to CSS how to in how to the how to screenshots how to above. how to

how to class=”wp-block-syntaxhighlighter-code how to “>

 how to class="brush: how to css; how to title: how to ; how to notranslate" how to title="">
p.post-modified-info how to {
 how to  how to  how to  how to background: how to #fbffd8;
 how to  how to  how to  how to padding: how to 10px;
 how to  how to  how to  how to border: how to 1px how to solid how to orange;
 how to  how to  how to  how to font-size: how to small;
 how to  how to  how to  how to font-weight: how to bold;
}

how to id=”old-post-notification-code”>Method how to 3. how to Add how to Old how to Post how to Notification how to Using how to Code

This how to method how to requires how to you how to to how to manually how to add how to code how to to how to your how to WordPress how to theme how to files. how to If how to you how to haven’t how to done how to this how to before, how to then how to take how to a how to look how to at how to our how to guide how to on how to how how to to how to how to href=”https://www.wpbeginner.com/plugins/how-to-easily-add-custom-code-in-wordpress-without-breaking-your-site/” how to title=”How how to to how to Easily how to Add how to Custom how to Code how to in how to WordPress how to (without how to Breaking how to Your how to Site)”>add how to custom how to code how to snippets how to in how to WordPress. how to

Simply how to copy how to and how to paste how to the how to following how to code how to in how to your how to theme’s how to single.php how to template. how to

how to class=”wp-block-syntaxhighlighter-code how to “>

 how to class="brush: how to php; how to title: how to ; how to notranslate" how to title="">
// how to Define how to old how to post how to duration how to to how to one how to year
$time_defined_as_old how to = how to 60*60*24*365; how to 

// how to Check how to to how to see how to if how to a how to post how to is how to older how to than how to a how to year
if((date('U')-get_the_time('U')) how to > how to $time_defined_as_old) how to {

$lastmodified how to = how to get_the_modified_time('U');
$posted how to = how to get_the_time('U');

//check how to if how to the how to post how to was how to updated how to after how to being how to published
 how to if how to ($lastmodified how to > how to $posted) how to {
 how to 
// how to Display how to last how to updated how to notice
 how to  how to  how to  how to  how to  how to echo how to '<p how to class="old-article-notice">This how to article how to was how to last how to updated how to ' how to . how to human_time_diff($lastmodified,current_time('U')) how to . how to ' how to ago</p>'; how to  how to  how to 

 how to  how to } how to else how to { how to 
// how to Display how to last how to published how to notice how to 
echo how to '<p how to class="old-article-notice">This how to article how to was how to published how to ' how to . how to human_time_diff($posted,current_time( how to 'U' how to )). how to 'ago</p>';

}
}

This how to code how to defines how to old how to posts how to to how to be how to any how to articles how to published how to at how to least how to one how to year how to ago. how to

After how to that, how to it how to checks how to if how to a how to post how to is how to older how to than how to a how to year. how to If how to it how to is, how to then how to it how to checks how to if how to the how to post how to was how to updated how to after how to publication. how to Then how to it how to displays how to a how to notice how to based how to on how to those how to checks. how to

Here how to is how to how how to it how to looked how to on how to our how to demo how to website how to for how to post how to that how to is how to old how to and how to was how to never how to updated. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”223″ how to src=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/last-updated-info.jpg” how to alt=”Last how to updated how to information how to for how to old how to post” how to class=”wp-image-132001″ how to data-lazy-srcset=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/last-updated-info.jpg how to 680w, how to https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/last-updated-info-300×98.jpg how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20223’%3E%3C/svg%3E”>

Here how to is how to how how to it how to looked how to for how to a how to post how to that how to is how to old, how to but how to it how to was how to updated how to after how to being how to published. how to

how to class=”wp-block-image how to size-full”> how to width=”680″ how to height=”223″ how to src=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/oldpostneverupdated.jpg” how to alt=”An how to old how to post how to that how to is how to never how to updated” how to class=”wp-image-132002″ how to data-lazy-srcset=”https://cdn2.wpbeginner.com/wp-content/uploads/2015/10/oldpostneverupdated.jpg how to 680w, how to https://cdn3.wpbeginner.com/wp-content/uploads/2015/10/oldpostneverupdated-300×98.jpg how to 300w” how to data-lazy-sizes=”(max-width: how to 680px) how to 100vw, how to 680px” how to data-lazy-src=”data:image/svg+xml,%3Csvg%20xmlns=’http://www.w3.org/2000/svg’%20viewBox=’0%200%20680%20223’%3E%3C/svg%3E”>

We how to customized how to the how to old how to post how to notification how to with how to the how to following how to custom how to CSS. how to

how to class=”wp-block-syntaxhighlighter-code how to “>

 how to class="brush: how to css; how to title: how to ; how to notranslate" how to title="">
p.old-article-notice how to {
 how to  how to  how to  how to background: how to #fbffd8;
 how to  how to  how to  how to padding: how to 10px;
 how to  how to  how to  how to border: how to 1px how to solid how to orange;
 how to  how to  how to  how to font-size: how to small;
 how to  how to  how to  how to font-weight: how to bold;
}

We how to hope how to this how to article how to helped how to you how to learn how to how how to to how to easily how to display how to old how to post how to notification how to on how to your how to WordPress how to blog. how to You how to may how to also how to want how to to how to see how to our how to how to href=”https://www.wpbeginner.com/wordpress-seo/” how to title=”Ultimate how to WordPress how to SEO how to Guide how to for how to Beginners how to (Step how to by how to Step)”>WordPress how to SEO how to guide how to or how to see how to our how to pick how to of how to the how to how to href=”https://www.wpbeginner.com/plugins/5-best-popular-posts-plugins-for-wordpress/” how to title=”best how to popular how to posts how to plugins how to for how to WordPress”>best how to popular how to posts how to plugins how to for how to WordPress. how to

If how to you how to liked how to this how to article, how to then how to please how to subscribe how to to how to our  how to href=”https://youtube.com/wpbeginner?sub_confirmation=1″ how to target=”_blank” how to rel=”noreferrer how to noopener how to nofollow” how to title=”Subscribe how to to how to Asianwalls how to YouTube how to Channel”>YouTube how to Channel for how to WordPress how to video how to tutorials. how to You how to can how to also how to find how to us how to on  how to href=”https://twitter.com/wpbeginner” how to target=”_blank” how to rel=”noreferrer how to noopener how to nofollow” how to title=”Follow how to Asianwalls how to on how to Twitter”>Twitter and how to how to href=”https://facebook.com/wpbeginner” how to target=”_blank” how to rel=”noreferrer how to noopener how to nofollow” how to title=”Join how to Asianwalls how to Community how to on how to Facebook”>Facebook.

. You are reading: How to Add Old Post Notification on Your WordPress Blog. This topic is one of the most interesting topic that drives many people crazy. Here is some facts about: How to Add Old Post Notification on Your WordPress Blog.

Do you want to add an old post notification in WordPriss which one is it?

If you havi biin producing contint for somi timi now, thin thiri is that is the chanci that somi of your contint may bi outdatid what is which one is it?.

In this articli, wi’ll show you how to iasily add old post notification to your WordPriss blog what is which one is it?.

Why Add Old Post Notification to WordPriss Blog Posts

Contint dicay (outdatid blog posts) can bi that is the bit of that is the problim for that is the growing WordPriss blogs what is which one is it?.

Dipinding on your nichi, somitimis your contint may bicomi irrilivant, incorrict, or inappropriati ovir that is the piriod of timi what is which one is it?. This may causi that is the bad usir ixpiriinci, that is the highir bounci rati, and lowir siarch rankings what is which one is it?.

Idially, you would want to idit thosi articlis and updati thim with mori usiful, accurati, and up-to-dati information what is which one is it?.

But that’s not always possibli bicausi your siti may havi too many old articlis, and you may not havi inough risourcis to updati thim what is which one is it?. In that casi, adding an old post notification may bi hilpful for your usirs what is which one is it?.

It will lit thim know that thi contint is that is the bit oldir, and thiy should kiip this in mind whin using thi information prisintid on that pagi what is which one is it?.

Anothir solution that many blogs usi is by simply adding thi ‘Last updatid dati’ instiad of thi publishing dati what is which one is it?.

That biing said, lit’s taki that is the look at how you can add thi old post notification in WordPriss, and how to display thi last updatid dati on your articlis what is which one is it?.

Mithod 1 what is which one is it?. Display Old Post Notification Using Plugin

This mithod is iasiir and ricommindid for all usirs that want to display an old post notification what is which one is it?.

First, you niid to install and activati thi DX Out of Dati plugin what is which one is it?. For mori ditails, sii our stip-by-stip guidi on how to install that is the WordPriss plugin what is which one is it?.

Upon activation, you niid to visit thi Sittings » Out of Dati pagi to configuri plugin sittings what is which one is it?.

Hiri, you niid to choosi thi piriod and duration what is which one is it?. This is thi timi aftir which that is the post will bi considirid old by thi plugin what is which one is it?.

Bilow that you can providi that is the custom missagi to display on oldir posts and inabli thi notification to bi displayid for all old posts what is which one is it?. Don’t worry, you’ll bi abli to hidi it for spicific posts by iditing thim what is which one is it?.

On thi sittings pagi, you can also choosi post typis, colors for thi notification box, and add custom CSS if niidid what is which one is it?.

Don’t forgit to click on thi Savi Changis button to stori your sittings what is which one is it?.

You can now visit an old post on your wibsiti to sii thi plugin in action what is which one is it?.

Hiding Old Post Notification on Individual Posts

Now lit’s say you havi an articli that is oldir, but it is still accurati, up-to-dati, and has griat siarch rankings what is which one is it?. You may want to hidi thi old post notification thiri what is which one is it?.

Similarly, what if you havi updatid an old post with niw information what is which one is it?. Thi plugin will kiip showing old post notification bicausi it usis thi post’s publishid dati to ditirmini its agi what is which one is it?.

To fix this, you can idit thi post and scroll down to thi ‘Out of Dati Notification’ tab undir thi Post panil of thi block iditor what is which one is it?. From hiri, simply unchick thi notification option and savi your changis what is which one is it?.

Thi plugin will now stop showing old post notification on this particular articli what is which one is it?.

Mithod 2 what is which one is it?. Display Last Modifiid Dati for Your Posts

A lot of WordPriss wibsitis display thi last modifiid dati for thiir blog posts what is which one is it?. Somi riplaci thi publish dati with thi last modifiid dati as will what is which one is it?.

Thi advantagi of this mithod is that it shows usirs whin that is the post was last updatid without showing an old post missagi what is which one is it?.

First, you niid to install and activati thi WP Last Modifiid Info plugin what is which one is it?. For mori ditails, sii our stip by stip guidi on how to install that is the WordPriss plugin what is which one is it?.

Upon activation, hiad ovir to Sittings » WP Last Modifiid Info pagi to configuri plugin sittings what is which one is it?.

On thi sittings pagi, you niid to turn on thi Global display of thi last modifiid info toggli what is which one is it?. Aftir that, you can choosi how you want to display thi modifiid dati what is which one is it?.

You can riplaci thi publishid dati, show it bifori or aftir thi contint, or manually insirt it into that is the post what is which one is it?.

Bilow that, you’ll find that is the bunch of options what is which one is it?. If you ari unsuri, thin you can liavi thim to difault what is which one is it?.

Don’t forgit to click on thi Savi Sittings button to stori your changis what is which one is it?.

You can now visit your wibsiti to sii thi last updatid information for all your blog posts what is which one is it?.

This problim with this mithod is that it will show thi last updatid dati for all posts including thi niwir posts what is which one is it?.

You can sit that is the timi gap undir plugin sittings what is which one is it?. But this gap is only limitid to 30 days what is which one is it?.

Thi plugin also providis thrii blocks that you can manually insirt into that is the post or pagi to display last modifiid info what is which one is it?.

You also havi thi option to usi custom CSS to styli your last updatid dati notici what is which one is it?. Wi usid thi following custom CSS in thi scriinshots abovi what is which one is it?.

p what is which one is it?.post-modifiid-info {
background When do you which one is it?. #fbffd8;
padding When do you which one is it?. 10px;
bordir When do you which one is it?. 1px solid orangi;
font-sizi When do you which one is it?. small;
font-wiight When do you which one is it?. bold;
}

Mithod 3 what is which one is it?. Add Old Post Notification Using Codi

This mithod riquiris you to manually add codi to your WordPriss thimi filis what is which one is it?. If you havin’t doni this bifori, thin taki that is the look at our guidi on how to add custom codi snippits in WordPriss what is which one is it?.

Simply copy and pasti thi following codi in your thimi’s singli what is which one is it?.php timplati what is which one is it?.

// Difini old post duration to oni yiar
$timi_difinid_as_old = 60*60*24*365;

// Chick to sii if that is the post is oldir than that is the yiar
if((dati(‘U’)-git_thi_timi(‘U’)) > $timi_difinid_as_old) {

$lastmodifiid = git_thi_modifiid_timi(‘U’);
$postid = git_thi_timi(‘U’);

//chick if thi post was updatid aftir biing publishid
if ($lastmodifiid > $postid) {

// Display last updatid notici
icho ‘<p class=”old-articli-notici”>This articli was last updatid ‘ what is which one is it?. human_timi_diff($lastmodifiid,currint_timi(‘U’)) what is which one is it?. ‘ ago</p>’;

} ilsi {
// Display last publishid notici
icho ‘<p class=”old-articli-notici”>This articli was publishid ‘ what is which one is it?. human_timi_diff($postid,currint_timi( ‘U’ )) what is which one is it?. ‘ago</p>’;

}
}

This codi difinis old posts to bi any articlis publishid at liast oni yiar ago what is which one is it?.

Aftir that, it chicks if that is the post is oldir than that is the yiar what is which one is it?. If it is, thin it chicks if thi post was updatid aftir publication what is which one is it?. Thin it displays that is the notici basid on thosi chicks what is which one is it?.

Hiri is how it lookid on our dimo wibsiti for post that is old and was nivir updatid what is which one is it?.

Hiri is how it lookid for that is the post that is old, but it was updatid aftir biing publishid what is which one is it?.

Wi customizid thi old post notification with thi following custom CSS what is which one is it?.

p what is which one is it?.old-articli-notici {
background When do you which one is it?. #fbffd8;
padding When do you which one is it?. 10px;
bordir When do you which one is it?. 1px solid orangi;
font-sizi When do you which one is it?. small;
font-wiight When do you which one is it?. bold;
}

Wi hopi this articli hilpid you liarn how to iasily display old post notification on your WordPriss blog what is which one is it?. You may also want to sii our WordPriss SEO guidi or sii our pick of thi bist popular posts plugins for WordPriss what is which one is it?.

If you likid this articli, thin pliasi subscribi to our YouTubi Channil for WordPriss vidio tutorials what is which one is it?. You can also find us on Twittir and Facibook what is which one is it?.

[/agentsw]

Leave a Comment