Problem:
The user would like to apply a secondary sorting on a custom field.
Solution:
Currently, Toolset views cannot use a custom field as a secondary order. The selection is limited to default fields, or randomly, instead of custom fields. Check this screenshot for the available secondary sorting options http://prntscr.com/tnbj4o
But we can work around it with custom code, by hooking into the query filters. Check the solution in this ticket https://toolset.com/forums/topic/sort-by-2-custom-fields/
Relevant Documentation:
- https://toolset.com/documentation/programmer-reference/views-filters/#wpv_filter_query
- https://codex.wordpress.org/Class_Reference/WP_Query
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
9:00 – 13:00 | 9:00 – 13:00 | 9:00 – 13:00 | 9:00 – 13:00 | - | - | 9:00 – 13:00 |
14:00 – 18:00 | 14:00 – 18:00 | 14:00 – 18:00 | 14:00 – 18:00 | - | - | 14:00 – 18:00 |
Supporter timezone: Africa/Casablanca (GMT+01:00)
This topic contains 2 replies, has 2 voices.
Last updated by 4 years, 4 months ago.
Assisted by: Jamal.