Advanced custom field search form
-
I need to create a custom search form that will add some dropdown filters to the basic search.
I have a custom post type called ‘ads’ and some custom fields with the keys of ‘country’ and ‘city’.How would I build the form to allow a user to search multiple custom fields, a custom post type, categories and a keyword.
For example; the user could type in ‘clown’ into the keyword input, and then select the ‘Variety’ category via a dropdown, and then select ‘United States’ (country custom field) via a dropdown and finally select ‘New York’ (city custom field) via another dropdown.
I’ve searched for hours and not found anything. I have no problem editing the code but am unsure of how to create a search query that will work. Surely someone has done something like this before??
Any help is appreciated.
- The topic ‘Advanced custom field search form’ is closed to new replies.