• Hello,

    I am trying to sold this without using a custom sql (since my SQL isn’t that great). I have some posts that are “sold” and some that aren’t. So I want to be able to sort the posts so that the “unsold” are shown first, then the “sold” ones.

    I have a “sold” tag and a custom field “sold”.

    I am trying a bunch of parameters but none seem to be working the way that I want it to.

    query_posts($query_string.'orderby=meta_key&order=DESC');?>

    the above does not work. Is there a way to order by tag?

    here is the URL:

    https://tomwong.ca/?cat=6

    (don’t mind the design)

    thanks,

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘trying to sort posts by custom field or tag’ is closed to new replies.