Title: Sorting events search
Last modified: August 31, 2016

---

# Sorting events search

 *  [krawe](https://wordpress.org/support/users/krawe/)
 * (@krawe)
 * [10 years ago](https://wordpress.org/support/topic/sorting-events-search/)
 * Consider the following code:
 * $events_result = $search->get_events_between($start_time, $end_time, array(),
   true);
 * Once I have data in the $events_result variable, how would it be possible to 
   sort the results? I would like to sort them by the event start time, in order
   of when they will be upcoming (so may 13th, 14th, then 15th for example).
 * Thanks in advance for your help. I have done a ton of searching but I can’t seem
   to find an answer on this.
 * [https://wordpress.org/plugins/all-in-one-event-calendar/](https://wordpress.org/plugins/all-in-one-event-calendar/)

The topic ‘Sorting events search’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/all-in-one-event-calendar.svg)
 * [Timely All-in-One Events Calendar](https://wordpress.org/plugins/all-in-one-event-calendar/)
 * [Support Threads](https://wordpress.org/support/plugin/all-in-one-event-calendar/)
 * [Active Topics](https://wordpress.org/support/plugin/all-in-one-event-calendar/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/all-in-one-event-calendar/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/all-in-one-event-calendar/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [krawe](https://wordpress.org/support/users/krawe/)
 * Last activity: [10 years ago](https://wordpress.org/support/topic/sorting-events-search/)
 * Status: not resolved