How to Add Updated Date Markup to Articles

By Posted 2013 Updated   BloggingSEOTutorialsWordPress

It is very important to add updated dates markup to your blog articles. Google and other search engines are tweaking their algorithms to favor fresh content. If you test your site on the structured data tool, it seems Updated date has become a necessary hentry requirement if you do microformats markup for all site pages. This is beside the article published date!

updatedWe have added the updated date to all our posts, besides the published post date. This is a good idea as people update old articles and content and this provides an official way for search engines to know when the content was updated. WordPress will save the date your content was updated and will help you publish the updated date easily.

What if you do not publish updated date?

If no Entry Updated element is present, it defaults to Entry Published element, and if that too is absent, then its invalid hAtom markup.

It is important that you add the post updated mark up to your html code and help search engines know when your post was last updated. Its is also important NOT to fool search engines like Google by labeling all content as updated today, if there are no changes in your page, because they are smart enough to detect changed content.

Markup Updated Date

How to markup the updated date?

Use this simple class updated to specify the updated date in your html code.

Can WordPress automatically display updated date?

Its easy. We use this code with the date and updated class. Then the the_modified_time php code prints the updated date automagically.

<span class="date updated"><time datetime="<?php the_modified_time('d/m/Y'); ?>"><?php the_modified_time('d/m/Y'); ?></time></span>

This code will publish the time your post was last updated. This is not the same  as your post published date (which should have a published class). You can choose different date format than d/m/Y as allowed by PHP time tags to customize the updated date the way you like it.

For example Y/m/d g:i:s A will output the date as 2013/07/09 12:51:28 AM

Should you replace original date with updated date?

Readers would like to know when the content was published. Outdated content corrected for grammatical errors will give a new updated date, but that does not make the 5 year old news item new for the reader. So we prefer to  keep both dates on our pages.

Update: learn how to add updated date to WordPress themes like 2013 or 2014 theme.


9 comments on “How to Add Updated Date Markup to Articles

  1. Adeelqamar says:

    Hey friend, read your post. Seems interesting. Can you please tell me that how can we add this update data class in Blogger blogs

  2. Hyptia says:

    This idea will give you better option to stay update with your readers because when you will post new blog frequently then your readers can get much benefits from your every blog post.

  3. Local Reviews says:

    This should really help with some of my stale content, thank you!

  4. reneta jemas says:

    Nice concept. I read it first time.

    Its working?

  5. Darrel says:

    Is there a plugin for this?

  6. Darrel says:

    I don’t understand the exact steps here. Do I add that code to the functions.php file?

  7. China says:

    thanks for sharing this post , I look forward in doing the change myself.I have hardly any idea of how to do this. I’m using thesis theme, so if I copy/past this code into the functions.php it will work?

  8. Helal Uddin says:

    Thanks for your nice sharing. Can I apply it to my blogger,s site?

Leave a Reply

Your email address will not be published. Required fields are marked *




css.php