I started creating a view for the custom search field and I'm having dificulties with the following:
1) When selecting a custom field by using New Filter, I choose the select dropdown menu and I put a label for the first default option, does that mean that if it's ALL, then it will show all options? For example, I have a custom field named Session which has 3 sessions to choose from (Terapeuta, Massagista, and Clinic). Once I create a custom search and place a Label named ALL, the results should show all three sessions, correct?
2) I'm trying to add a conditional output for a selection field. I want to only show if the previous selection is 1. For example, I have state (Estado), two options, if the visitor chooses 1, then I want it to show the cities (Cidade), if the visitor chooses 1 for city, then I want it to show Neighborhoods (Bairros), and if the visitor chooses #2, to show Streets (Ruas).
But the conditional output is giving an error and not showing it. Screenshot attached.
Can the custome field content be something else besides a number? Text instead?
1) Great! That's what I wanted to know.
2) It worked and I had to add the AND function as well to hide another parameter. I also had to change to "AJAX results update when visitors change any filter values" in order for the other option to show when the user changes the field. But, the option on the dropdown menu only shows the first option and not the rest on all the search fields. Why? How can I fix that? (See screenshot). Also the options for a radio (yes or no) is only showing one item or none.
3) When creating a radio and the visitor does not choose any, it should show both, correct? And if he chooses one and then wants to clear that section, he would have to reset the search?
Also, I have a website custom post field but it does not show the URL, it can only show a link, why is that? How can I show the URL of the website?
Images attached
How do I make the search result show in alphabetic order by post title? (see image)
How do I make a button to change the alphabetic order from A - Z and Z - A?
But, the option on the dropdown menu only shows the first option and not the rest on all the search fields. Why?
I'm not sure what you mean by this, is it that the filter isn't showing all the available options ?
Also the options for a radio (yes or no) is only showing one item or none.
I'm assuming here that the option you are talking about is "sim" . I noticed in your other posts the option is now present. Is this still an issue ?
3) When creating a radio and the visitor does not choose any, it should show both, correct? And if he chooses one and then wants to clear that section, he would have to reset the search?
You mean if the user doesn't select Yes or No ?
In a case like this if the user didn't select anything then the filter will be ignored. If they selected something and want to clear it then yes they would need to use the reset button.
Sorry, I thought I could use the thread to include the other issues too. I'll create other tickets for the other issues.
I'm not sure what you mean by this, is it that the filter isn't showing all the available options ?
Yes! The other available options are not showing. As I think about it, I think the other options only show if there are being used by the custom post. Meaning, when I created the custom post type with custom fields for the user to select and he has not selected that, it would not show in the custom search option. Because I created only two custom post to test it and it only shows the options those custom posts selected. I hope you can understand what I mean.
Also the options for a radio (yes or no) is only showing one item or none.
I'm assuming here that the option you are talking about is "sim" . I noticed in your other posts the option is now present. Is this still an issue ?
Sim means yes in Portuguese. Again I believe it has to do with the options chosen from the user. In my sample tests (2 custom posts, Felipe and Akemi) I believe I chose Yes in the Promotions tab (Promoções) for both of them, therefore it only shows Yes, instead of showing Yes and No. Is that the reason? Can't the search show both options then if the visitor chooses an option that is not available it would show "nothing was found."
You mean if the user doesn't select Yes or No ?
In a case like this if the user didn't select anything then the filter will be ignored. If they selected something and want to clear it then yes they would need to use the reset button.
Yes you clarified it for me. Thanks!
Maybe if I explain a bit better, it would make sense. I'm creating a classified Ad site with user registration. I created custom type and created some fields where users need to choose and enter their info and eventually show in the front end. Therefore if the custom field offers 10 options for the user to choose and the user chooses one, the other nine will not show as an option in the custom search section for the visitors (not users), is that correct?
Is there a way to show all available option even though the user did not choose those options? For example, I create 2 states in the custom field "Estado" but ALL of our current clients (users) are in Rio, therefore when the someone visits the website, it should show both "Estados" (states) but at the search result it would say, "could not find results" because there are no users who chose the other state.
1. This is how it actually works if you've enabled the settings for it. It ensures that your search will always return a result. You can actually disable this.
To disable it go to your Custom Search Settings in views.
Click on "Let me choose individual settings manually"
Then under "Which options to display in the form inputs" select "Always show all values for inputs"
2. This one is definitely related to my answer in 1 above.