Title: Table sorting
Last modified: July 11, 2020

---

# Table sorting

 *  Resolved [royalscribe](https://wordpress.org/support/users/royalscribe/)
 * (@royalscribe)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/table-sorting-5/)
 * When using the `[tdih_tab]` function to create a table (such as for all events
   in a given month), the table sorts by calendar date. For example, an entry for
   July 10, 1980 sorts before an entry for July 15, 1965. Is there a way to tell
   it to sort chronologically (by year, then month, then day) rather than only by
   calendar day, so that the 1965 event appears before the 1980 event?

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Anonymous User 393930
 * (@anonymized-393930)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13178951)
 * There is no way to currently change the sort order of the shortcodes.
 * I’ll need to look into this a bit. It should already be in ascending year-month-
   day order but this doesn’t seem to be always be the case.
 *  [ssegedy](https://wordpress.org/support/users/ssegedy/)
 * (@ssegedy)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13210101)
 * I’m also curious about this, and hoping to see chronological sorting regardless
   of the order or which part of the date (year, month, everything, etc.) is being
   displayed.
 *  [cathymoranhajo](https://wordpress.org/support/users/cathymoranhajo/)
 * (@cathymoranhajo)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13257572)
 * It sorts that way in the Admin view, but on the public page it reverts to a sort
   by 01-01-YYYY
 *  Anonymous User 393930
 * (@anonymized-393930)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13317891)
 * Thanks for reporting this issue. It is fixed in version 3.7.3.
 *  [URLmedia](https://wordpress.org/support/users/urlmedia/)
 * (@urlmedia)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13320543)
 * with the recent update my list has changed from sorting to day, month, year to
   now reads year, day, month.
    In other words the year is the priority which i 
   don’t want. I need to have the table show the day first, so all events on this
   day show in the one day irrespective of year eg.
 * 09-08-2020 Died on this day
    15-08-2019 Died on this day 15-08-2020 Died on this
   day 18-08-2019 Died on this day 18-08-2020 Died on this day 21-08-2019 Died on
   this day 21-08-2020 Died on this day
 * At the moment it is sorted by year which it was not before. I am using the code:[
   tdih_tab month=c]. Is there a new shortcode i have to use?

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Table sorting’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/this-day-in-history.svg)
 * [This Day In History](https://wordpress.org/plugins/this-day-in-history/)
 * [Support Threads](https://wordpress.org/support/plugin/this-day-in-history/)
 * [Active Topics](https://wordpress.org/support/plugin/this-day-in-history/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/this-day-in-history/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/this-day-in-history/reviews/)

## Tags

 * [sort](https://wordpress.org/support/topic-tag/sort/)
 * [sorting](https://wordpress.org/support/topic-tag/sorting/)

 * 5 replies
 * 5 participants
 * Last reply from: [URLmedia](https://wordpress.org/support/users/urlmedia/)
 * Last activity: [5 years, 9 months ago](https://wordpress.org/support/topic/table-sorting-5/#post-13320543)
 * Status: resolved