Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author piccart

    (@piccart)

    Hello!

    if you select sort by metafield, then you also have to provide the meta name of the field that you want to order by.
    if you look a bit below that option, there is a selector for MetaField Name.

    you will need to select the slug/name of the field (which might be different from the label that you see in your admin editor, but usually it is very similar).

    Though, it is not 100% sure that it will work as expected because if it’s a date it depends on how it is stored in the database. If you are lucky it is stored as a timestamp, or as a date with YEAR-MONTH-DAY, and if you select “numeric meta field” then it should work. Otherwise I am sorry but there isn’t anything I can do because it depends on how the field has been setup (which depends on how it is used).

    though, try both selecting the numeric or not selecting it, and see which among ASC or DESC is sorting in the way you need.

    you can live the “meta compare” as it is, it won’t be considered if you leave empty the “meta value” (if you put a value there, then it will be used to filter the posts and display only the ones which match the “meta compare” against that “meta value”, for the field “meta field name”).

    Metafields can be a bit tricky to grasp if you’re not used to them. I hope now it’s clearer. let me know if you still have doubts!

    cheers!

    Thread Starter biswazr

    (@biswazr)

    Thank you for your guidance.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Meta Field need to set meta key name’ is closed to new replies.