Forums › Forums › Search & Filter Pro › Search in one category only
Tagged: Avada, one category
- This topic has 26 replies, 3 voices, and was last updated 8 years, 6 months ago by Trevor.
-
Anonymous(Private) April 21, 2016 at 5:37 pm #43573
Hello Ross,
I needed a form to display results using Post Type Archive but I can’t have two forms (or more) that displays results like this, so I had to use Archive (which in my theme looks like a blog and it’s not useful for me).
So I spoke to Trevor about it and we had a skype videocall in which we found out that Avada wouldn’t let me use a custom results.php page.
The reason I need a custom results.php is because of the way search results are displayed in my website.
This is the form that displays results using Post Type Archive: http://www.edulynks.com/prueba
I use this form to search the availability of schools depending of the type of program (academic years, summer camps, etc) and country (USA, UK, France, etc).This is the form that filters results within a type of program using Archive: http://www.edulynks.com/campamentos-de-verano
I use this form to filter schools within a type of program, for example, if the program is summer camps, I want to filter those summer camps depending of the country (summer camps in canada, summer camps in france, etc).Originally what I wanted to do is use the Post Type URL to display results like Post Type Archive like I read here but I found out that it wouldn’t work because of Avada, so Trevor suggested that I use a custom Archive page (results.php). I placed my custom results.php in the /themes/Avada/search-filter directory but it’s giving me an error: “Error: The custom template file results.php cannot be found”.
Please tell me if I explained myself clearly or if you need extra information 😀
Thank you!
Anonymous(Private) April 21, 2016 at 5:39 pm #43574This is the post that I read about using Post Type URL to display results like Post Type Archive https://support.searchandfilter.com/forums/topic/2-search-forms-for-same-post-type-archive/
Anonymous(Private) April 26, 2016 at 4:59 pm #43986Hello Ross! Thanks, this worked perfectly but I have one question and I’d like to know if it’s possible to do, I can even pay for this extra customization.
I’ve created one S&F for each programme and I’ve set them up the in a way that it is now possible to look for programmes according to their availability in each country in a friendly way. However, the way it’s set up now is a bit confusing for our users, therefore, we’d like to know if it’s possible to set a category as a default in each form so it automatically shows the countries the programme is available in.
For example: In “Cursos de Idiomas“, I’d like to have the “Cursos de Idiomas” as default, so in the dropdown, it will only display the countries we have schools in.
Is this possible? Are you available for this job? How much would it be?
Thank you!
Ross Moderator(Private) April 27, 2016 at 11:44 am #44118Hey Harumi
I’m afraid I’m too busy to take on any extra work, but it is possible already to do something similar.
This does require a certain level of dev knowledge though, here you have the filter input object:
This would allow you to set a particular option to “selected” in the search form. Check the advanced gist linked on that page for an example how “defaults” work.
Once you have done this, you would also need to modify the query, to look inside a particular category for example – so you would need to modify the using this filter:
Again these are some more advanced features that require a certain level of knowledge of WP & coding, but it is possible – I’m just unable to find the time to do this.
I’m hoping to add something more user friendly in a future update.
Thanks
-
AuthorPosts