query order by date on custom type: wrong order

It is meta_key not meta-key meaning you aren’t meeting all of the conditions needed for this to work.

‘meta_value_num’ – Order by numeric meta value (available with
Version 2.8). Also note that a ‘meta_key=keyname’ must also be present
in the query. This value allows for numerical sorting as noted above
in ‘meta_value’.

Leave a Comment