• Resolved nmi3

    (@nmi3)


    Hello,

    I have created a custom post type for “properties” with a taxonomy for “size”. At the moment, taxonomies are being sorted as: 1-500 | 1001-1500 | 1501-2000 | 2000+ | 501-1000

    I need them to sort as: 1-500 | 501-1000 | 1001-1500 | 1501-2000 | 2000+

    Is there a way to do this? I am implementing a filtering system that will filter “properties” by “size” using a dropdown and I need the taxonomies to be in the order specified.

    Thank you.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Not a topic our plugin deals with, but I’ll do what I can to point in a right direction.

    Where is this in regards to? The list in the sidebar of the post editor screen? Somewhere on the frontend where you’re querying for them all? From the looks of it, they’re being ordered by term name, not necessarily numeral. If you have control of the list of terms before they’re output, you could potentially utilize some php to re-order them.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Replying so I can get myself notified by email for new replies.

    Thread Starter nmi3

    (@nmi3)

    Hi Michael! Thank you!

    “Somewhere on the frontend where you’re querying for them all”

    Yes. I am using the Search and Filter plugin to allow users to search for “properties” and filter the results by “size” as well as other taxonomies all on the frontend. The list order on the front-end is the same as the backend.

    I was searching for possible solutions and came across a few that required php. Most of them were not using a plugin to create custom post types or taxonomies so I wasn’t sure if it would work. I am also not very familiar with php. Any help in the right direction is greatly appreciated.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    I assume you mean https://ww.wp.xz.cn/plugins/search-filter/

    Not sure how they grab the terms, but I wager they’re probably using get_terms(). They may be the better place to inquire about this, to be honest.

    CPTUI’s job is done in that it gets the taxonomies/post types registered and available

    Thread Starter nmi3

    (@nmi3)

    Got it, thanks.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Custom Taxonomy Order’ is closed to new replies.