Support

Account

Home Forums General Issues Sorting woocommerce products by ACF Date Picker field Reply To: Sorting woocommerce products by ACF Date Picker field

  • The only reason that I can come up with for your original code not working is that the date field is some type of sub field. You have done it according to the documentation I can find.

    You do not understand the relationship between the display format and the save format, unless you are using an older version of ACF the value is always saved “YMD” and this format does not need to be reflected in the query.

    The only reason it would is if you are using a very old version of ACF or the values in these fields were saved using a very old version of ACF and have not been updated since they were originally created. Even here that would not make sense because if the site was kept up to date all along then when ACF changed the way is saved values your fields should have been updated during the upgrade process. This upgrade may not have been done but only if you updated from a very old version of ACF to a very new version of ACF.

    My suggestion is to look in the DB and see exactly what is stored for this date field.