Problem:
An earlier solution built on Types 2 stopped working after migrating to Types 3. How is it now possible to order a View of parent posts by the count of child posts related to each parent?
Solution:
This requires writing custom code that modifies the main View query, an example of which is proposed below: https://toolset.com/forums/topic/after-relationships-update-code-views-ordering-is-not-working/#post-1177723
Relevant Documentation:
https://toolset.com/documentation/programmer-reference/views-filters/#wpv_filter_query
https://toolset.com/documentation/customizing-sites-using-php/post-relationships-api/#toolset_get_related_posts
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.
Our next available supporter will start replying to tickets in about 0.05 hours from now. Thank you for your understanding.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
- | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | - |
- | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | - |
Supporter timezone: Europe/London (GMT+00:00)
This topic contains 9 replies, has 2 voices.
Last updated by 5 years, 11 months ago.
Assisted by: Nigel.