WordPress.org

Plugin Directory

Relative Date

Display a relative date (e.g. "4 days ago")

Relative dates are where, instead of showing the exact date of a post, you can say it was posted "4 days ago". Tomorrow, this message would say "5 days ago". This plugin has been designed to be called from your theme (manually or automaticall) to display these relative dates, as required.

All relative dates are shown up to 2 depths and are not designed to be 100% accurate (due to rounding), but rather to give the reader an idea as to how old something is.

Some examples...

Something that is 1 year and 2 months and 3 weeks old will be output as "1 year, 2 months". Something that is 2 year and 0 months and 3 weeks old will be output as "2 years, 3 weeks".

Key features include...

  • Change your theme yourself or automatically convert the dates
  • Set output depth and your own dividers
  • Specify two dates if you wish so you can add your own time range
  • And much, much more!

Technical specification...

  • Licensed under GPLv2 (or later)
  • Designed for both single and multi-site installations
  • PHP7 compatible
  • Fully internationalized, ready for translations If you would like to add a translation to his plugin then please head to our Translating WordPress page
  • WCAG 2.0 Compliant at AA level

But, most importantly, there are no premium features and no adverts - this is 100% complete and free! See the "Other Notes" tab for how to get started as well as the more advanced features.

Requires: 2.5 or higher
Compatible up to: 4.6.2
Last Updated: 4 days ago
Active Installs: 100+

Ratings

2 out of 5 stars

Support

Got something to say? Need help?

Compatibility

+
=
Not enough data

1 person says it works.
0 people say it's broken.

100,1,1
100,1,1
0,2,0
100,1,1
100,1,1