Automatically sorting custom post type admin area by a custom field
Rather save the event meta field date(s) as a unix-timestamp, instead of a string, or you’ll be making life too difficult for yourself. It just makes date comparisons so much easier. Here’s an example of how to convert your YYYY/MM/DD format to a unix timestamp: $date=”2010/09/22″; $dateParts = explode(“https://wordpress.stackexchange.com/”, trim($date)); if (count($dateParts) == 3) { … Read more