Hello everyone (Merry Christmas), I’m just using EE to create a small website. I can not understand how I can make filters for custom channel fields.
I have a channel “Properties” with fields {id_immobile} type Number, {common} type String, {contract} type String and {type} type String. All have the Include check mark in the search.
I created a Form inspired by that in the documentation but I do not think is correct.
{exp:search:advanced_form channel="immobili" result_page="immobili/search"}
<!--<input type="hidden" name="search_in" value="entries"/>-->
<input type="hidden" name="where" value="word"/>
<div class="form-group">
<select class="form-control" name="keywords">
<option selected disabled>Seleziona Contratto</option>
<option value="Vendita">Vendita</option>
<option value="Affitto">Affitto</option>
</select>
</div>
<div class="form-group">
<select class="form-control" name="">
<option selected disabled>Seleziona un Comune</option>
{exp:channel:entries channel="comuni"}
<option value="{title}">{title}</option>
{/exp:channel:entries}
</select>
</div>
<div class='searchSubmit'>
<input type='submit' value='Search' class='submit' />
</div>
{/exp:search:advanced_form}
I would like the research to work based on choices.
I want to create a search filter for the first Select OR second Select OR third Select.
Example: I select only Contract-> Sale of the first Select, it must find all the Properties that have the custom field named {Contract}. Selecting Sale of the first select and an option of the second Select (Exp. Contract-> Italy), must find all the Properties that have the custom field named {Contract} and custom field named {Municipality}
I hope I have made my problem better understand this way.
Thanks in advance
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.