Forums › Forums › Search & Filter Pro › Order alphabetically by custom taxonomies
Tagged: sorting alphabetically
- This topic has 2 replies, 2 voices, and was last updated 8 years, 8 months ago by
Anonymous.
-
Anonymous(Private) August 29, 2016 at 3:32 pm #55951
Hey!
I’m thinking about creating a kind of table like view, where the columns would have titles like post title, author and date and the rows would list this information from all posts. I want it to be possible to change the order by clicking the column titles, for example if I click date, it would show order by date descending and if I click again, would change it to ascending. And with the other fields, the order would be alphabetical. I think it could be possible with the sort order field and some custom js and css.
However, in addition to the sorting options that I mentioned, I would like to use custom taxonomies and also sort by them alphabetically. Is that possible? I can’t find them in the sorting options, not even in meta value. I can see ACF fields there, should I just use those if it’s not possible to sort with taxonomies? I’m doing this with a custom post type, I’m still designing it and thinking what would be the best way to do it. So I could do it with ACF, but I thought custom taxonomies would be easier, since I could use the ones that already exist for another post type that I’m using. So, is there a way to use the taxonomies, or do you have any other suggestions?
Thanks!
Trevor(Private) August 30, 2016 at 10:30 am #56021I’m thinking about creating a kind of table like view, where the columns would have titles like post title, author and date and the rows would list this information from all posts. I want it to be possible to change the order by clicking the column titles, for example if I click date, it would show order by date descending and if I click again, would change it to ascending. And with the other fields, the order would be alphabetical. I think it could be possible with the sort order field and some custom js and css.
I do not know if this would work, and it is outside of our normal support.
However, in addition to the sorting options that I mentioned, I would like to use custom taxonomies and also sort by them alphabetically. Is that possible?
I do not think that this is possible.
I can see ACF fields there, should I just use those if it’s not possible to sort with taxonomies?
If that works for you …
So, is there a way to use the taxonomies, or do you have any other suggestions?
Not that I can think of.
Anonymous(Private) September 1, 2016 at 8:37 am #56304Well thanks a lot.
I do not know if this would work, and it is outside of our normal support.
I didn’t ask help for that, I can figure it out. Just mentioned it to give some background about why I need to sort something with taxonomies.
In case anyone else comes here and wants to do something similar, you can use Advanced Custom Fields. I added an ACF field to my custom post type, set the field type to Taxonomy and chose the category that I wanted to use. Then with Search & filter pro I created a Sort order field and added a meta value option. From the Meta Key list I found the ACF field I had created, and that’s how I’ll be able to sort by taxonomy. So I think this will work for me, but maybe not for everyone.
-
AuthorPosts