Support › Meta Box Group › Using clonable field as param in pre_get_posts filterResolved
i want to using value in my custom field, there is in multiple nested clonable group, as a param in pre_get_post filter for custom search on the frontend.
For example i have multiple nested group in my custom post type and one field hold color information - this value i want to check in search result using pre_get_posts filter. Hope, you understood me.
Can you show me a way for accomplish this issue pls?
The question relates to this topic https://support.metabox.io/topic/best-approach-when-it-comes-to-query-by-custom-field/.
I recommend using a single field or cloneable field with the setting clone_as_multiple (not in a group). Why? Because the group is used for storing data, not for querying.
See more in these articles:
thank you for your answer - it helped me.