... /busca?tipo%5B%5D=APARTAMENTO%2FAPTO+DUPLEX&area_de=50&area_at=100
In this URL I have 2 data types:
type that is checkbox
- APARTMENT
- FIT + DUPLEX
area_of which is select
- 50
area_at which is select
- 100
How do I persist this data after the search? How to make them checked
or selected
so that the search is not requested and that it is enough to give another search with one or another different parameter without having to reschedule everything again?
Update
Dear, the HTML is very extensive, because I put a part in the question to be able to solve the rest based on the response, as requested, here is the HTML . This is the HTML of the entire search.
Form HTML Code
<form action="/busca" method="GET" name="frm_busca" id="frm_busca">
<fieldset class="w255">
<legend>Tipo</legend>
<input type="checkbox" name="tipo[]" value="APARTAMENTO/APTO DUPLEX" id="tp1">
<label for="tp1">Apartamento</label>
<input type="checkbox" name="tipo[]" value="CASA" id="tp2">
<label for="tp2">Casa</label>
</fieldset>
<fieldset class="w145">
<legend>Dormitórios</legend>
<input type="checkbox" name="dorm[]" value="1" id="dorm1">
<label for="dorm1">1</label>
<input type="checkbox" name="dorm[]" value="2" id="dorm2">
<label for="dorm2">2</label>
<input type="checkbox" name="dorm[]" value="3" id="dorm3">
<label for="dorm3">3</label>
<input type="checkbox" name="dorm[]" value="4" id="dorm4">
<label for="dorm4">4+</label>
</fieldset>
</form>