Toolset Types
Sort archive page asc/desc using Custom Field (2 posts)

  1. wpwebdlr
    Posted 3 years ago #

    I am trying to create links for users to sort either ascending or descending based off a custom field. For example, I have numeric fields for number of bedrooms and number of bathrooms. I'm trying to make links at the top of the page so that the user can sort the listings by either of those two options.

    I've tried using the suggested WP post query string and have looked around the Types API codes but I'm not able to query any custom fields.

    Is there a certain way you should format your query for it to return the custom fields in either ascending or descending order? I've tried using meta_key without success. Also, I've tried meta_key with using the wpcf- prefix and also without it.


  2. mbigul
    Posted 3 years ago #

    Hi wpwebdlr,

    Can you please share the query code you have used. Hope you are using WordPress 3.5.1 and Types 1.2.2

    [ Signature moderated. ]

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Toolset Types
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic